I added a new npm package to my project and require it in one of my modules.
Now I get this message from webpack,
build modulesNote: The code generator
This seems to be a Babel error. I'm guessing you use babel-loader, and are not excluding external libraries from your loader test. As far as I can tell, the message is not harmful, but you should still do something like this:
loaders: [
{ test: /\.js$/, exclude: /node_modules/, loader: 'babel' }
]
Have a look. Was that it?
I tried Ricardo Stuven's way but it didn't work for me. What worked in the end was adding "compact": false to my .babelrc file:
{
"compact": false,
"presets": ["latest", "react", "stage-0"]
}
This is maybe not the case of original OP question, but: if you exceeds the default max size, this maybe a symptom of some other issue you have. in my case, I had the warrning, but finally it turned into a FATAL ERROR: MarkCompactCollector: semi-space copy, fallback in old gen Allocation failed - JavaScript heap out of memory. the reason was that i dynamically imported the current module, so this ended up with an endless loop...