报错如下
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! vue-manage-system@3.2.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 vue-manage-system@3.2.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! C:\Users\admin\AppData\Roaming\npm-cache_logs\2018-11-09T07_28_28_466Z-debug.log
解决:卸载已安装的新版本webpack,装老版本就好。如果没有安装webpack,跳过第一条命令安装一下就好了。
(1)依次输入以下命令
npm uninstall webpack-dev-server
(2)安装2.9.1的webpack
npm install webpack-dev-server@2.9.1
(3)运行项目
npm run dev