运行npm run dev报错,找了好的方法都不好用,求大神!!!
发布于 3 年前 作者 banyungong 1480 次浏览 来自 问答
粉丝福利 : 关注VUE中文社区公众号,回复视频领取粉丝福利

hongyu@1.0.0 dev /Users/tanchang/www/vue/hongyu
webpack-dev-server --inline --progress --config build/webpack.dev.conf.js

/Users/tanchang/www/vue/hongyu/build/webpack.dev.conf.js:53
new webpack.NoEmitOnErrorsPlugin(),
^

TypeError: webpack.NoEmitOnErrorsPlugin is not a constructor
at Object. (/Users/tanchang/www/vue/hongyu/build/webpack.dev.conf.js:53:5)
at Module._compile (internal/modules/cjs/loader.js:776:30)
at Object.Module._extensions…js (internal/modules/cjs/loader.js:787:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
at Module.require (internal/modules/cjs/loader.js:690:17)
at require (internal/modules/cjs/helpers.js:25:18)
at module.exports (/Users/tanchang/www/vue/hongyu/node_modules/webpack/bin/convert-argv.js:80:13)
at Object. (/Users/tanchang/www/vue/hongyu/node_modules/webpack-dev-server/bin/webpack-dev-server.js:68:48)
at Module._compile (internal/modules/cjs/loader.js:776:30)
at Object.Module._extensions…js (internal/modules/cjs/loader.js:787:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:829:12)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! hongyu@1.0.0 dev: webpack-dev-server \--inline \--progress \--config build/webpack.dev.conf.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the hongyu@1.0.0 dev script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /Users/tanchang/.npm/_logs/2019-07-17T07_13_20_165Z-debug.log

回到顶部