There's prolly something really obvious here that I'm missing. Plugin seems to refuse to work with my stack, which is a fork of http://juhamust.github.io/silverplate
$ git diff
diff --git a/package.json b/package.json
index 140f670..e6aaff4 100644
--- a/package.json
+++ b/package.json
@@ -51,6 +51,7 @@
"normalize.css": "^3.0.3",
"postcss-loader": "^0.8.0",
"precss": "^1.4.0",
+ "prepack-webpack-plugin": "^1.1.0",
"raw-loader": "^0.5.1",
"resolve-url": "^0.2.1",
"resolve-url-loader": "^1.4.3",
diff --git a/webpack.config.js b/webpack.config.js
index 3fa42f4..fbf1b74 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -5,6 +5,7 @@ var CommonsChunkPlugin = require('webpack/lib/optimize/CommonsChunkPlugin');
var autoprefixer = require('autoprefixer');
var precss = require('precss');
var packageInfo = require('./package.json');
+var PrepackWebpackPlugin = require('prepack-webpack-plugin').default;
module.exports = {
context: __dirname,
@@ -30,6 +31,8 @@ module.exports = {
},
noParse: [],
plugins: [
+ new PrepackWebpackPlugin({
+ }),
new ExtractTextPlugin('app.css', { allChunks: true }),
new HtmlWebpackPlugin({
version: packageInfo.version,
$ npm start
[...]
/home/tero/src/silverplate/node_modules/prepack-webpack-plugin/dist/PrepackPlugin.js:27
return chunk.hasRuntime() && chunk.isInitial();
^
TypeError: chunk.hasRuntime is not a function
at isEntryChunk (/home/tero/src/silverplate/node_modules/prepack-webpack-plugin/src/PrepackPlugin.js:23:16)
There's prolly something really obvious here that I'm missing. Plugin seems to refuse to work with my stack, which is a fork of http://juhamust.github.io/silverplate
Steps to reproduce
git clone https://github.com/juhamust/silverplate.gitnpm installnpm install prepack-webpack-plugin --save-devAfter this
Then fire it up
There seems to be abundance of causes for
chunk.hasRuntime is not a functionand I couldn't find out how to make it work.