[英]On start new react project I have this problem
When I run npm start
, I get this error.当我运行
npm start
,出现此错误。 What is the solution for this?解决这个问题的方法是什么?
This issue has been addressed here , you can refer to it. 这里已经解决了这个问题,你可以参考一下。
Complete solution is完整的解决方案是
%SystemRoot%/system32/WindowsPowerShell/v1.0
.%SystemRoot%/system32/WindowsPowerShell/v1.0
。Set-ExecutionPolicy Unrestricted -Scope CurrentUser -Force
.Set-ExecutionPolicy Unrestricted -Scope CurrentUser -Force
。npm-windows-upgrade
.npm-windows-upgrade
。Check your node version.检查您的节点版本。 update node & npm try sudo npm start if you are in macOS or linux try to download create-react-app again npm i -g create-react-app try to create the app in another folder create-react-app APPNAME Still not working?
更新节点和 npm 尝试 sudo npm start 如果您在 macOS 或 linux 中尝试再次下载 create-react-app npm i -g create-react-app 尝试在另一个文件夹中创建应用 create-react-app APPNAME 仍然无法正常工作? Then delete node module folder and run npm install Not yet?
然后删除 node 模块文件夹并运行 npm install 还没有? delete both node module & package-lock.json and npm install Try to run on another PORT
删除节点模块和 package-lock.json 和 npm install 尝试在另一个端口上运行
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.