Error occurred when executing command: npm run serve

[0] Error occurred when executing command: npm run serve
[0] Error: spawn cmd.exe ENOENT
[0]     at Process.ChildProcess._handle.onexit (internal/child_process.js:264:19)
[0]     at onErrorNT (internal/child_process.js:456:16)
[0]     at processTicksAndRejections (internal/process/task_queues.js:80:21)
[1] Error occurred when executing command:  nodemon mock/index.js 
[1] Error: spawn cmd.exe ENOENT
[1]     at Process.ChildProcess._handle.onexit (internal/child_process.js:264:19)
[1]     at onErrorNT (internal/child_process.js:456:16)
[1]     at processTicksAndRejections (internal/process/task_queues.js:80:21)
[1]  nodemon mock/index.js  exited with code -4058
[0] npm run serve exited with code -4058

执行npm run dev 命令出错

将命令改为npm run serve 即可解决

Error occurred when executing command: npm run serve_第1张图片

你可能感兴趣的:(nodejs)