在运行vue项目时报如下问题:

E:\mobile_real\mobile-vue>npm run dev

> mobile_real@1.0.0 dev E:\mobile_real\mobile-vue

> webpack-dev-server --inline --progress --config build/webpack.dev.conf.js

npm ERR! code ELIFECYCLE

npm ERR! errno 1

npm ERR! mobile_real@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 mobile_real@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\FKT00120\AppData\Roaming\npm-cache\_logs\2019-05-27T01_45_54_024Z-debug.log

查阅资料发现是webpack新版bug,卸载现有webpack,安装老版本即可

解决办法:

1、npm uninstall webpack-dev-server

2、npm install webpack-dev-server@2.9.1

3、npm run dev

vue npm run dev报错webpack-dev-server的更多相关文章

  1. vue-electron 使用sqlite3数据库,执行npm run build 报错 .NET Framework 2.0 SDK,Microsoft Visual Studio 2005[C:\temp\wechat\node_modules\sqlite3\build\binding.sln]

    问题描述 vue-electron 使用sqlite3数据库,执行npm run build 报错如下: .NET Framework 2.0 SDK,Microsoft Visual Studio ...

  2. create-react-app创建项目后,运行npm run eject报错解决方法

    运行npm run eject报错解决方法 主要问题是脚手架添加.gitgnore文件,但是却没有本地仓库,使用以下命令操作以下就可以了 git init git add . git commit - ...

  3. vue中执行npm run build报错解决方法?

    遇到了执行npm run build 后报错: [build:js ] Module not found: Error: Can't resolve 'scss-loader' in 'D:\work ...

  4. 转载:TypeError: Cannot read property 'compilation' of undefined vue 打包运行npm run build 报错

    转载自:https://www.jianshu.com/p/3f8f60e01797 运行npm run build打包时,报错如下:   我的package.json如下: { ... " ...

  5. create-react-app 构建的项目使用释放配置文件 webpack 等等 运行 npm run eject 报错

    使用 git 提交一次记录即可正常 git add . git commit -m 'init' npm run eject

  6. 在package.json中配置Script执行npm run tslint报错问题

    今天在学习tslint的时候,按照git clone下angular2-webpack-starter的代码执行npm run lint时,虽然代码进行了检测,但检测完成后npm始终报错, //pac ...

  7. npm run build报错(npm ERR! code ELIFECYCLE)的解决办法

    具体报错如下图: 环境:centos7 应该node_modules安装问题,我们需要重新安装 rm -rf node_modules rm package-lock.json npm cache c ...

  8. 使用create-react-app命令创建一个项目, 运行npm run eject报错

    解决方法: 先 git add . 然后 git commit -m ‘init’ 然后再npm run eject

  9. vue2.x 在引用插件的时候,npm run dev跑正常 ,npm run build 报错vue-cli Unexpected token: punc (() [

    这是因为,引用的插件在node_modules里,并不在vue-cli的es6编译范围内,所以语法报错,修改方法:

  10. npm run build报错 ,resolve is not defined

    今天在build项目的时候报: ReferenceError: resolve is not defined npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ...

随机推荐

  1. 翻译 - Kafka Streams 介绍(一)

    2019独角兽企业重金招聘Python工程师标准>>> 资料 [原文地址](http://kafka.apache.org/11/documentation/streams/) 正文 ...

  2. opencv-11-中值滤波及自适应中值滤波

    开始之前 在上一篇我们实现了读取噪声图像, 然后 进行三种形式的均值滤波得到结果, 由于我们自己写的均值滤波未作边缘处理, 所以效果有一定的下降, 但是总体来说, 我们得到的结果能够说明我们的算法执行 ...

  3. JAVA编程思想 Ch3.6题

    练习6:在练习5的基础上,创建一个新的Dog索引,并对其赋值为Spot对象.测试用==和equals()方法来比较引用结果. public class quan { String name; Stri ...

  4. CF--思维练习--CodeForces - 216C - Hiring Staff (思维+模拟)

    ACM思维题训练集合 A new Berland businessman Vitaly is going to open a household appliances' store. All he's ...

  5. 化妆品行业的一个MES系统案例(三)

    项目的主要需求如下: (1) 管理产品的配方(物料BOM) (2) 管理产品的生产工艺(最终要将工艺参数下发到设备PLC自动执行) (3) 根据生产工单集合产品配方生成称量任务(其实领料之后的成料过程 ...

  6. SpringBoot:整合SpringSecurity

    目录 SpringSecurity(安全) 搭建环境 使用 用户认证和授权 注销及权限控制 记住我及登录页面定制 SpringBoot 整合 SpringSecurity: 用户认证和授权.注销及权限 ...

  7. 龙贝格算法 MATLAB实现

    龙贝格算法主要是不断递推和加速,直到满足精度要求 递推: 加速: 得到T表: MATLAB代码: function I = Romberg(f, a, b, epsilon) I = 0; h = b ...

  8. 利用css+js制作下拉列表

    利用文本框来制作,可以不影响给后台传数据.<!DOCTYPE html> <html> <head> <style> *{;;;} body{font- ...

  9. LeetCode--Array--Two sum (Easy)

    1.Two sum (Easy)# Given an array of integers, return indices of the two numbers such that they add u ...

  10. Coursera课程笔记----P4E.Capstone----Week 2&3

    Building a Search Engine(week 2&3) Search Engine Architecture Web Crawling Index Building Search ...