[email protected] build D:\myFile\vue-devtools-dev
cd packages/shell-chrome && cross-env NODE_ENV=production webpack --progress --hide-modules
'webpack' 不是内部或外部命令,也不是可运行的程序
或批处理文件。
events.js:187
throw er; // Unhandled 'error' event
^
Error: spawn webpack ENOENT
at notFoundError (D:\myFile\vue-devtools-devnode_modules\cross-spawn\lib\enoent.js:6:26)
at verifyENOENT (D:\myFile\vue-devtools-devnode_modules\cross-spawn\lib\enoent.js:40:16)
at ChildProcess.cp.emit (D:\myFile\vue-devtools-devnode_modules\cross-spawn\lib\enoent.js:27:25)
at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
Emitted 'error' event on ChildProcess instance at:
at ChildProcess.cp.emit (D:\myFile\vue-devtools-devnode_modules\cross-spawn\lib\enoent.js:30:37)
at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12) {
code: 'ENOENT',
errno: 'ENOENT',
syscall: 'spawn webpack',
path: 'webpack',
spawnargs: [ '--progress', '--hide-modules' ]
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] build: cd packages/shell-chrome && cross-env NODE_ENV=production webpack --progress --hide-modules
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] build 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\DELL\AppData\Roaming\npm-cache_logs\2020-01-07T09_36_44_396Z-debug.log
Hello, thank you for taking time filling this issue!
However, we kindly ask you to use our Issue Helper when creating new issues, in order to ensure every issue provides the necessary information for us to investigate. This explains why your issue has been automatically closed by me (your robot friend!).
I hope to see your helper-created issue very soon!
你好,你的 issue 不符合我们所要求的格式,因此已被自动关闭。为了确保每个 issue 都提供必需的相关信息,请务必使用我们的 Issue 向导 来创建新 issue,谢谢!
请问这个问题解决了吗
这个问题是CMD无法识别webpack命令,需要下载webpack,全局安装的webpack没用,使用yarn add -D -W webpack-cli下载webpack,然后在npm run build,这个需要的时间可能比较长,有可能需要5分钟耐心等待
Most helpful comment
这个问题是CMD无法识别webpack命令,需要下载webpack,全局安装的webpack没用,使用yarn add -D -W webpack-cli下载webpack,然后在npm run build,这个需要的时间可能比较长,有可能需要5分钟耐心等待