npm ERR! code ELIFECYCLE

Posted 持.之.以.恒

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了npm ERR! code ELIFECYCLE相关的知识,希望对你有一定的参考价值。

“E:\\Program Files\\JetBrains\\WebStorm 2018.1.4\\bin\\runnerw.exe” G:\\node\\nodejs\\node.exe G:\\node\\nodejs\\node_modules\\npm\\bin\\npm-cli.js run dev –scripts-prepend-node-path=auto

hrvue@1.0.0 dev G:\\front\\my-project 
webpack-dev-server –inline –progress –config build/webpack.dev.conf.js

‘webpack-dev-server’ �����ڲ����ⲿ���Ҳ���ǿ����еij��� 
���������ļ��� 
npm ERR! code ELIFECYCLE 
npm ERR! errno 1 
npm ERR! hrvue@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 hrvue@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! C:\\Users\\linghongkang\\AppData\\Roaming\\npm-cache_logs\\2018-06-14T07_17_34_269Z-debug.log

Process finished with exit code 1

解决:原因是因为你的node_modules有意外改动,导致依赖库不完整。 
删除项目下的node_modules,在你的项目目录下,重新执行npm install,这会重新生成node_modules, 
执行npm run build , 
npm run dev.

 

以上是关于npm ERR! code ELIFECYCLE的主要内容,如果未能解决你的问题,请参考以下文章

vue项目webpack打包失败,npm ERR! code ELIFECYCLE

输入npm install 报错npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! node-sass@4.13.1 postinstall: `no

npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! test_vue_0613@1.0.0 dev: 错误的解决方法

“npm ERR!code ELIFECYCLE”在标准输出或调试文件中没有更多信息

Heroku 最近开始在 Webpack 构建期间给出部署错误“npm ERR!code ELIFECYCLE”

如何解决 npm 错误“npm ERR!代码 ELIFECYCLE”