If there's an error in the compilation process somewhere (say a SyntaxError in my JS when piped through babel), IndexHtmlWebpackPlugin will swallow the error and I'll get this TypeError instead:
/Project/node_modules/indexhtml-webpack-plugin/IndexHtmlSource.js:154
var chunkJsFile = _.find(chunkForEntry.files, function (file) {
^
TypeError: Cannot read property 'files' of undefined
at Object.<anonymous> (/Project/node_modules/indexhtml-webpack-plugin/IndexHtmlSource.js:154:59)
at [object Object].exports.each (/Project/node_modules/cheerio/lib/api/traversing.js:293:24)
at IndexHtmlSource._resolveScripts (/Project/node_modules/indexhtml-webpack-plugin/IndexHtmlSource.js:141:17)
at IndexHtmlSource.source (/Project/node_modules/indexhtml-webpack-plugin/IndexHtmlSource.js:28:10)
at CompressionPlugin.<anonymous> (/Project/node_modules/compression-webpack-plugin/index.js:31:25)
at /Project/node_modules/compression-webpack-plugin/node_modules/async/lib/async.js:111:13
at Array.forEach (native)
at _each (/Project/node_modules/compression-webpack-plugin/node_modules/async/lib/async.j
...
Commenting out the IndexHtmlPlugin line in my webpack.config.js allows the error to go through correctly.
If there's an error in the compilation process somewhere (say a SyntaxError in my JS when piped through babel), IndexHtmlWebpackPlugin will swallow the error and I'll get this TypeError instead:
Commenting out the IndexHtmlPlugin line in my webpack.config.js allows the error to go through correctly.