[email protected] build D:\app\social-h5\mall-master
node build/build.js
D:\app\social-h5\mall-master\[email protected]@web-webpack-plugin\lib\WebPlugin.js:99
compiler.hooks.webPluginBeforeEmitHTML = new SyncHook(['htmlDocument']);
^
TypeError: Cannot set property 'webPluginBeforeEmitHTML' of undefined
at WebPlugin.apply (D:\app\social-h5\mall-master\[email protected]@web-webpack-plugin\lib\WebPlugin.js:99:42)
at Object.keys.forEach (D:\app\social-h5\mall-master\[email protected]@web-webpack-plugin\lib\AutoWebPlugin.js:179:7)
at Array.forEach ()
at AutoWebPlugin.apply (D:\app\social-h5\mall-master\[email protected]@web-webpack-plugin\lib\AutoWebPlugin.js:156:25)
at Compiler.apply (D:\app\social-h5\mall-master\[email protected]@tapable\lib\Tapable.js:375:16)
at webpack (D:\app\social-h5\mall-master\[email protected]@webpack\lib\webpack.js:32:19)
at Object. (D:\app\social-h5\mall-master\build\build.js:24:1)
at Module._compile (internal/modules/cjs/loader.js:701:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:712:10)
at Module.load (internal/modules/cjs/loader.js:600:32)
at tryModuleLoad (internal/modules/cjs/loader.js:539:12)
at Function.Module._load (internal/modules/cjs/loader.js:531:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:754:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:622:3)
深入浅出webpack学习中。采用最新版4.6.7 同样遇到该问题。1.0.0 正常编译