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
There is not way to turn off decorator transpilation processing so that it passes through. I use babel for filling and compiling down to my target javascript environment so typically I do not want tsc to transpile modern javascript features. target=esnext helps ensure that tsc assumes that the target environment is quite modern.
However, if there is a decorator in the ts file, it is translated into __decorate(...) regardless of what settings I might use to try and keep it intact into my next compilation stage, which is babel.
@freezeclassFoo{ ... }
Even using esnext as the target, you get in the source:
... =__decorate(...)
But we really want pass through like many other features of javascript that pass through when esnext is set:
@freeze
class Foo { ... }
The text was updated successfully, but these errors were encountered:
Automatically closing this issue for housekeeping purposes. The issue labels indicate that it is unactionable at the moment or has already been addressed.
TypeScript Version: 2.6.0-rc
There is not way to turn off decorator transpilation processing so that it passes through. I use babel for filling and compiling down to my target javascript environment so typically I do not want tsc to transpile modern javascript features. target=esnext helps ensure that tsc assumes that the target environment is quite modern.
However, if there is a decorator in the ts file, it is translated into __decorate(...) regardless of what settings I might use to try and keep it intact into my next compilation stage, which is babel.
Even using esnext as the target, you get in the source:
But we really want pass through like many other features of javascript that pass through when esnext is set:
The text was updated successfully, but these errors were encountered: