我正在尝试使用react和django遍历不好的tuto的react和django来做一个完整的堆栈项目,这是我流动的tuto的django应用程序,当它要执行流动的命令npm run dev和dev时,它是一个django应用程序 "dev":" webpack --mode development ./leadmanager/frontend/src/index.js --output-path ./leadmanager/frontend/static/main.js",
我有一些错误
(venv) youssef@youssef-HP-EliteBook-840-G3:~/Desktop/fullstack$ npm run dev
> fullstack@1.0.0 dev /home/youssef/Desktop/fullstack
> webpack --mode development ./leadmanager/frontend/src/index.js --output-path ./leadmanager/frontend/static/
[webpack-cli] Running multiple commands at the same time is not possible
[webpack-cli找到的命令:'bundle','。/leadmanager/frontend/src/index.js'webpack-cli运行'webpack --help'以查看可用的命令和选项
npm ERR!代码ELIFECYCLE
npm ERR! errno 2
npm ERR! fullstack@1.0.0开发人员:
webpack --mode development ./leadmanager/frontend/src/index.js --output-path ./leadmanager/frontend/static/
npm ERR!退出状态2npm ERR!
npm ERR!在fullstack@1.0.0开发脚本处失败。
npm ERR! npm可能不是问题。上面可能还有其他日志记录输出。
npm ERR! A complete log of this run can be found in:
npm ERR! /home/youssef/.npm/_logs/2020-12-29T13_19_24_663Z-debug.log
最佳答案
从docs尝试按以下方式使用它:webpack --mode development --entry ./leadmanager/frontend/src/index.js --output-path ./leadmanager/frontend/static/main.js
注意--entry
而且,您可能还想更改--output-path
部分,使其看起来像:--output-path ./leadmanager/frontend/static/frontend/
关于reactjs - webpack-cli不能同时运行多个命令,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/65493070/