Bundler Typescript failing on TS type alias #10024
-
Hi, I'm super new to using swc and I'm trying to use it for bundling my typescript to js targeting the browser. I'm using the swc rust crates directly (swc_bundler, etc). When attempting to feed it a file that contains a type alias, I get this error:
I'm not sure why I'm getting this. This is the Syntax configuration I am using:
and the bundler config:
I can post the full source if needed, but hoping this is just a simple misunderstanding on my part of how to do something simple. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I think I was able to get this working. I noticed that the ts_to_js strips all ts types using
This got me past that error (and bundling worked just fine). |
Beta Was this translation helpful? Give feedback.
I think I was able to get this working. I noticed that the ts_to_js strips all ts types using
strip
, so I tried that out like this:This got me past that error (and bundling worked just fine).