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
We make a lot of use of Typescript decorators in our code base. In Nuxt 2.14 they could be used in places outside of webpack module resolution, such as Nuxt modules. In Nuxt 2.15 they are no longer supported, because the babel instance bundled with Jiti doesn't have the @babel/plugin-proposal-decorators plugin.
I would propose that if opts.ts and ideally only when experimentalDecorators === true (from tsconfig), this plugin be added: _opts.plugins!.push([require('@babel/plugin-proposal-decorators'), { legacy: true }])
The text was updated successfully, but these errors were encountered:
Could babel-plugin-transform-typescript-metadata also please be added so that the metadata added by these decorators can be used, say for dependency injection.
We make a lot of use of Typescript decorators in our code base. In Nuxt 2.14 they could be used in places outside of webpack module resolution, such as Nuxt modules. In Nuxt 2.15 they are no longer supported, because the babel instance bundled with Jiti doesn't have the
@babel/plugin-proposal-decorators
plugin.I would propose that if
opts.ts
and ideally only whenexperimentalDecorators === true
(from tsconfig), this plugin be added:_opts.plugins!.push([require('@babel/plugin-proposal-decorators'), { legacy: true }])
The text was updated successfully, but these errors were encountered: