我从Pluralsight教程下载了一个项目文件夹,当我尝试使用npm start运行它时,会显示以下消息:
[webpack-cli] Unable to load '@webpack-cli/serve' command [webpack-cli] TypeError: options.forEach is not a function at WebpackCLI.makeCommand (C:\Users\Israel Juarez\Desktop\before\node_modules\webpack-cli\lib\webpack-cli.js:173:21)
at ServeCommand.apply (C:\Users\Israel Juarez\Desktop\before\node_modules\@webpack-cli\serve\lib\index.js:41:19) at loadCommandByName (C:\Users\Israel Juarez\Desktop\before\node_modules\webpack-cli\lib\webpack-cli.js:907:35) at async Command.<anonymous> (C:\Users\Israel Juarez\Desktop\before\node_modules\webpack-cli\lib\webpack-cli.js:1462:17) at async Promise.all (index 0) at async WebpackCLI.run (C:\Users\Israel Juarez\Desktop\before\node_modules\webpack-cli\lib\webpack-cli.js:1500:9) at async runCLI (C:\Users\Israel Juarez\Desktop\before\node_modules\webpack-cli\lib\bootstrap.js:11:9)
npm ERR! code ELIFECYCLE npm ERR! errno 2 npm ERR! ps-redux@1.0.0 start:
webpack serve --config webpack.config.dev.js --port 3000
npm ERR! Exit status 2 npm ERR! npm ERR! Failed at the ps-redux@1.0.0 start 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\Israel Juarez\AppData\Roaming\npm-cache_logs\2021-10-20T17_42_05_820Z-debug.log