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
The default ts-loader doesn't appear to work correctly, as it then never gets Babelified. Looks like it needs to be babel-loader!ts-loader instead of just ts-loader?
Digging further.
The text was updated successfully, but these errors were encountered:
That is, the loader needs to be set to Babel (with @babel/preset-typescript added to the babelrc?) in order to parse the Babel parts from files (see this post). react-scripts does the same; they're also using ForkTsCheckerWebpackPlugin (matching this example); it's probably worth considering this, because ts-loader is hella slow at scale.
@rmccue Thanks for this catch. Could I ask you to put together a gist or a PR that demonstrates the issue? Should be able to get this fix in pretty quickly if so. Otherwise, it may need to wait for the next major as I should be able to allocate some more significant time once @igmoweb's Webpack 5 pr is ready to fly, and could tackle this during that.
The default ts-loader doesn't appear to work correctly, as it then never gets Babelified. Looks like it needs to be
babel-loader!ts-loader
instead of justts-loader
?Digging further.
The text was updated successfully, but these errors were encountered: