This particular translation causes problems with esbuild and esbuild-based frameworks like vite.
esbuild does not support TypeScript's emitDecoratorMetadata functionality, so we must use this brilliant Babel plugin to inject the missing metadata before running esbuild.
On the other hand, esbuild can handle TypeScript's parameter decorators perfectly well. Internally, esbuild does the same kind of translation as this Babel plugin + @babel/plugin-proposal-decorators (in legacy mode), but implemented differently.
But if this Babel plugin translates parameter decorators to function expressions, and the result is fed to esbuild, then esbuild errors out.
Therefore, could you please add an option to disable the translation of parameter decorators?
Thanks!
This particular translation causes problems with esbuild and esbuild-based frameworks like vite.
esbuild does not support TypeScript's
emitDecoratorMetadatafunctionality, so we must use this brilliant Babel plugin to inject the missing metadata before running esbuild.On the other hand, esbuild can handle TypeScript's parameter decorators perfectly well. Internally, esbuild does the same kind of translation as this Babel plugin +
@babel/plugin-proposal-decorators(in legacy mode), but implemented differently.But if this Babel plugin translates parameter decorators to function expressions, and the result is fed to esbuild, then esbuild errors out.
Therefore, could you please add an option to disable the translation of parameter decorators?
Thanks!