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
// Part 1functionextender(myClass){returnclassextendsmyClass{}}// Part 2constExtended=extender(class{});newExtended();
The following code:
Works, if transpiled to es6+
Works, if transpiled to es5 too
Doesn't work, if the first part gets transpiled to es5 while the second part is still using es6. The first part may very well be a class decorator exported by some third-party package. The problem is that when transpiled down to es5 classes can't extend native classes.
Playground Link: N/A, the playground is too limited for this
The text was updated successfully, but these errors were encountered:
TypeScript Version: 3.4.1
Search Terms: extend class transpiled es5
Code
The following code:
Playground Link: N/A, the playground is too limited for this
The text was updated successfully, but these errors were encountered: