Tapable is deprecated in Webpack 4
https://github.com/webpack/webpack/issues/6568#issuecomment-377491754
Here's the trace with process.traceDeprecation = true a top of webpack.base.conf.js
(node:97338) DeprecationWarning: Tapable.plugin is deprecated. Use new API on `.hooks` instead
at Object.<anonymous> (/Volumes/git/x-web/build/dev-server.js:42:10)
at Module._compile (internal/modules/cjs/loader.js:702:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:713:10)
at Module.load (internal/modules/cjs/loader.js:612:32)
at tryModuleLoad (internal/modules/cjs/loader.js:551:12)
at Function.Module._load (internal/modules/cjs/loader.js:543:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:744:10)
at startup (internal/bootstrap/node.js:240:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:564:3)
Line 41+ of dev-server
// force page reload when html-webpack-plugin template changes
compiler.plugin('compilation', function (compilation) {
compilation.plugin('html-webpack-plugin-after-emit', function (data, cb) {
hotMiddleware.publish({ action: 'reload' })
cb()
})
})
The solution seems to be compiler.hooks.done.tap('compilation', function (compilation) { though I'm really unsure about what any of this is for
Was this ever cured somewhere else? I am having the same issue using the latest version so far as I can tell?
My solution was to migrate to vue-cli, I have no idea what Webpack version it uses... but it's not longer our concern when using it. It wasn't as difficult as I predicted... the hardest part was setting computed env vars, but even that was relatively easy
@rayfoss that is my typical first choice, however, I have a few existing apps that don’t use it and I have to “roll my own”.
To be quite honest, I am surprised this issue still exists?
Shouldn't be... CLI has been pushed hard over the last year, and it doesn't have that issue. The issue happens when you upgrade to Webpack 4, it's actually easier to upgrade to CLI v3
On Tue, Sep 4, 2018 at 10:37 AM Mike Erickson [email protected] wrote:
@rayfoss https://github.com/rayfoss that is my typical first choice, however, I have a few existing apps that don’t use it and I have to “roll my own”.
To be quite honest, I am surprised this issue still exists?
— You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub https://github.com/vuejs-templates/pwa/issues/194#issuecomment-418414881, or mute the thread https://github.com/notifications/unsubscribe-auth/AA1eLGVH-lFDHwwvFaFtnh9fCrHBnmAoks5uXp4rgaJpZM4U6nVN .
--
Ray Foss