解决vue项目运行过程中,npm run dev 报错问题
2023-09-11 14:19:07 时间
【方案1】
错误如下:
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! travel@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 travel@1.0.0 dev script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
npm ERR! A complete log of this run can be found in:
npm ERR! D:\Program Files\nodejs\node_cache\_logs\2018-08-01T09_05_17_312Z-debug.log
原因:这是新版webpack存在的BUG,卸载现有的新版本webpack,装老版本就好。
(1)、npm uninstall webpack-dev-server (2)、npm install webpack-dev-server@2.9.1 (3)、npm run dev
【方案2】
npm install -save
npm run dev
.
相关文章
- vue blob流下载zip文件
- django-vue 混合开发
- 解决JS(Vue)input[type='file'] change事件无法上传相同文件的问题
- vue 自定义指令input表单的数据验证
- Vue.js
- [Vue @Component] Define Props on a Vue Class with vue-property-decorator
- [Vue @Component] Simplify Vue Components with vue-class-component
- [Vue-rx] Share RxJS Streams to Avoid Multiple Requests in Vue.js
- [NPM] Create a bash script to replace a complex npm script
- [NPM] Run npm scripts in parallel
- 使用vue搭建应用三引入scss
- [NPM] Publish npm packages using npm publish
- [NPM] List available npm scripts and support tab completion
- [Vue] Get up and running with vue-router
- [NPM] Use custom config settings in your npm scripts
- vue.js3: 用crypto-js做sha加密(vue@3.2.37 / crypto-js@4.1.1)
- npm install时报平台不兼容Unsupported platform for xxx的解决办法:npm install -f强制安装(centos7下安装vite2 vue依赖时出现这个问题)
- vue-tour快速入门:VUE项目中如何使用vue-tour新手引导指引插件?怎样使用?包含具体实例
- 怎样给vue项目重命名
- win10 安装vue 详解-包括node.js、npm、webpack
- Vue:a标签点击和file-saver实现文件下载
- Vue、Vuejs从入门到精通 | vue-router详解
- Vue(八)vue 脚手架、脚手架创建项目示例
- Vue(二)vue 指令及用法举例
- 如何解决npm run serve运行vue项目时,出现报错:Error: error:0308010C:digital envelope routines::unsupported
- 基于Java+SpringBoot+Vue前后端分离电影院售票订票系统设计与实现(有演示视频)
- vue实现点击后多级标题联动变化
- vue第三天
- Vue.js - webpack相关配置