My webpack.prod.conf.js is from a newer template than yours; in my version, webpack attempts to split the webpack runtime into a manifest.js file. When I blindly copied your explicit chunks statement into my template, it caused the generated index.html to exclude this manifest, which resulted in webpack not getting loaded (you get a runtime JS error like "webpackjsonp is not defined"
The solution is to explicitly mention manifest in the chunks block.
Here's the code from my vue-cli template:
// extract webpack runtime and module manifest to its own file in order to
// prevent vendor hash from being updated whenever app bundle is updated
new webpack.optimize.CommonsChunkPlugin({
name: 'manifest',
minChunks: Infinity
}),
My
webpack.prod.conf.js
is from a newer template than yours; in my version, webpack attempts to split the webpack runtime into amanifest.js
file. When I blindly copied your explicitchunks
statement into my template, it caused the generatedindex.html
to exclude this manifest, which resulted in webpack not getting loaded (you get a runtime JS error like "webpackjsonp is not defined"The solution is to explicitly mention
manifest
in thechunks
block.Here's the code from my vue-cli template:
I'd recommend changing the line
to
in this file https://github.com/lean/phaser-es6-webpack/blob/28b3021e52bcbd0ce425b9ce593a94bde06aef2a/webpack.config.js#L38