1

When I use both HtmlWebpackPlugin and CommonsChunkPlugin in a webpack config, I get an error saying Uncaught TypeError: Cannot read property 'call' of undefined.

enter image description here

Some people say that minChunks has not to be callback but Infinity. But I just wanna use callback to split all third party libs from node_modules.

I know this issue has similar questions but none of them are helpful to me.

Here is my webpack.config.js

Thanks a lot in advance.

Here is the versions I use below.

  • node v6.9.5

  • webpack v2.2.1

Ryo Ikarashi
  • 341
  • 4
  • 11

0 Answers0