You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+30Lines changed: 30 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,6 +2,36 @@
2
2
3
3
## Unreleased
4
4
5
+
* Support TypeScript experimental decorators on `abstract` class fields ([#3684](https://github.com/evanw/esbuild/issues/3684))
6
+
7
+
With this release, you can now use TypeScript experimental decorators on `abstract` class fields. This was silently compiled incorrectly in esbuild 0.19.7 and below, and was an error from esbuild 0.19.8 to esbuild 0.20.1. Code such as the following should now work correctly:
8
+
9
+
```ts
10
+
// Original code
11
+
const log = (x:any, y:string) =>console.log(y)
12
+
abstractclassFoo { @logabstract foo:string }
13
+
newclassextendsFoo { foo ='' }
14
+
15
+
// Old output (with --loader=ts --tsconfig-raw={\"compilerOptions\":{\"experimentalDecorators\":true}})
16
+
const log = (x, y) =>console.log(y);
17
+
classFoo {
18
+
}
19
+
newclassextendsFoo {
20
+
foo ="";
21
+
}();
22
+
23
+
// New output (with --loader=ts --tsconfig-raw={\"compilerOptions\":{\"experimentalDecorators\":true}})
0 commit comments