run vue task的项目报错:Error while running task C:\IT\xxxxxx:serve with message‘spawn vue-cli-service
{ Error: spawn vue-cli-service ENOENTat notFoundError (C:\Users\wyhui\AppData\Roaming\npm\node_modules\@vue\cli\node_modules\cross-spawn\lib\enoent.js:6:26)at verifyENOENT (C:\Users\wyhui\AppData\Roam
·
{ Error: spawn vue-cli-service ENOENT
at notFoundError (C:\Users\wyhui\AppData\Roaming\npm\node_modules\@vue\cli\node_modules\cross-spawn\lib\enoent.js:6:26)
at verifyENOENT (C:\Users\wyhui\AppData\Roaming\npm\node_modules\@vue\cli\node_modules\cross-spawn\lib\enoent.js:40:16)
at ChildProcess.cp.emit (C:\Users\wyhui\AppData\Roaming\npm\node_modules\@vue\cli\node_modules\cross-spawn\lib\enoent.js:27:25)
at Process.ChildProcess._handle.onexit (internal/child_process.js:240:12)
code: 'ENOENT',
errno: 'ENOENT',
syscall: 'spawn vue-cli-service',
path: 'vue-cli-service',
spawnargs: [ 'serve', '--mode', 'development', '--dashboard' ] }
运行vue项目的时候报上面这个错,解决方法:删掉node_modules,重新cnpm install一下就好了。
更多推荐
已为社区贡献5条内容
所有评论(0)