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
Operating System and version (if applicable): macOS
Node Version (if applicable):
Does it work with tsc (if applicable): yes
Reproduction
Hard to reproduce except locally, comparing results?
Expected Behavior
So, I saw that this plugin added support for swc. Previously, I had code like:
isProd
? ts({hook: {// Always rename declaration files to index.d.ts to avoid emitting two declaration files with identical contentsoutputPath: (path,kind)=>kind==='declaration' ? './index.d.ts' : path}})
: swc(swcConfig)
In other words, if I needed to generate types, I'd pipe it through rollup-plugin-ts. If not, I'd pipe it through rollup-plugin-swc. However, when this plugin added support for SWC, I decided I could test it with the transpiler: 'swc' option, and do something more like:
ts({
transpiler: 'swc',
tsconfig: isProd ? 'tsconfig.prod.json' : 'tsconfig.json',
hook: {
// Always rename declaration files to index.d.ts to avoid emitting two declaration files with identical contents
outputPath: (path, kind) => kind === 'declaration' ? './index.d.ts' : path
}
})
Actual Behavior
The problem is, even if I don't export a declaration, for whatever reason, rollup-plugin-ts is orders of magnitude slower than rollup-plugin-swc. I don't understand how / why this is the case, if it should just be piping transpilation through swc and not doing anything else?
The text was updated successfully, but these errors were encountered:
tsc
(if applicable): yesReproduction
Hard to reproduce except locally, comparing results?
Expected Behavior
So, I saw that this plugin added support for swc. Previously, I had code like:
In other words, if I needed to generate types, I'd pipe it through
rollup-plugin-ts
. If not, I'd pipe it throughrollup-plugin-swc
. However, when this plugin added support for SWC, I decided I could test it with thetranspiler: 'swc'
option, and do something more like:Actual Behavior
The problem is, even if I don't export a declaration, for whatever reason,
rollup-plugin-ts
is orders of magnitude slower thanrollup-plugin-swc
. I don't understand how / why this is the case, if it should just be piping transpilation throughswc
and not doing anything else?The text was updated successfully, but these errors were encountered: