Emit generated name for unnamed default exported class with decorated members

This commit is contained in:
Ron Buckton
2017-04-19 15:12:22 -07:00
parent 77e96b651e
commit 571bce515c
17 changed files with 235 additions and 1 deletions
@@ -0,0 +1,8 @@
// @target: ES2015
// @module: ES2015
// @experimentaldecorators: true
declare function dec<T>(target: any, propertyKey: string, descriptor: TypedPropertyDescriptor<T>): TypedPropertyDescriptor<T>;
export default class {
@dec get accessor() { return 1; }
}
@@ -0,0 +1,8 @@
// @target: ES2015
// @module: ES2015
// @experimentaldecorators: true
declare function dec<T>(target: any, propertyKey: string, descriptor: TypedPropertyDescriptor<T>): TypedPropertyDescriptor<T>;
export default class {
@dec method() {}
}
@@ -0,0 +1,8 @@
// @target: ES2015
// @module: ES2015
// @experimentaldecorators: true
declare function dec(target: Object, propertyKey: string | symbol, parameterIndex: number): void;
export default class {
method(@dec p: number) {}
}
@@ -0,0 +1,8 @@
// @target: ES2015
// @module: ES2015
// @experimentaldecorators: true
declare function dec(target: any, propertyKey: string): void;
export default class {
@dec prop;
}