swc/bundler/tests/fixture/issue-1156-1/output/entry.ts
Nayeem Rahman 9bc074ed46
fix(strip): Combine typescript_class_properties() into strip() (#1478)
swc_ecma_utils:
 - Use `&mut` for inject_after_super.

swc_ecma_transforms_typescript:
 - Merge `typescript_class_properties` into `strip`.

Co-authored-by: 강동윤 <kdy1997.dev@gmail.com>
2021-03-21 22:31:35 +09:00

23 lines
358 B
TypeScript

function d() {
let methods;
const promise = new Promise((resolve, reject)=>{
methods = {
resolve,
reject
};
});
return Object.assign(promise, methods);
}
class A {
a() {
this.s.resolve();
}
b() {
this.s = d();
}
constructor(){
this.s = d();
}
}
new A();