react-refresh-webpack-plugin icon indicating copy to clipboard operation
react-refresh-webpack-plugin copied to clipboard

[feat] Add `thread-loader` support

Open mjames-c opened this issue 3 weeks ago • 0 comments

We (Canva) have noticed that ReactRefreshLoader is adding non-negligible overhead to our webpack builds. For example, our development startup build time increased by ~15% (from 3m30s to 4m).

It would be great for us if ReactRefreshWebpackPlugin could be setup to work with thread-loader to reduce this overhead (similar to our other TypeScript loaders).

// example API
module.exports = {
  plugins: [new ReactRefreshWebpackPlugin()],
  module: {
    rules: [
      {
        test: /\.tsx?$/i,
        use: {
          loader: ReactRefreshWebpackPlugin.loader,
        },
        exclude: /node_modules/i
      },
    ],
  },
};

mjames-c avatar Dec 01 '25 19:12 mjames-c