解決npx create-react-app速度過慢的問題


以管理員身份運行cmd

 

切換npm源:

npm config set registry https://registry.npm.taobao.org

 

切換yarn源:

yarn config set registry https://registry.npm.taobao.org

 

安裝或更新create-react-app版本:

npm i -g create-react-app

 

查看create-react-app版本

create-react-app -V

 

使用create-react-app腳手架創建React應用程序:

npx create-react-app my-app

 

運行剛才創建的應用:

cd my-app

yarn start

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM