craco icon indicating copy to clipboard operation
craco copied to clipboard

How to use thread-loader in craco?

Open Kujo-Jotaro-AAAAA opened this issue 2 years ago • 0 comments

How to use thread-loader in craco?

module: {
      rules: [
        {
          test: /.js$/,
          include: path.resolve(__dirname, '../src'),
          use: [
            // 'babel-loader',
            {
              loader: 'thread-loader',
              options: {
                workers: 3,
              },
            },
          ],
        },
      ],
    }

But,It won't work

error message: Error: Can't find a 'oneOf' rule under module.rules in the production webpack config!

Kujo-Jotaro-AAAAA avatar May 13 '22 07:05 Kujo-Jotaro-AAAAA