create-react-app 創建項目沒有src目錄,提示you're using an outdated version of create-react

報錯信息:

A template was not provided. This is likely because you’re using an outdated version of create-react-app.
Please note that global installs of create-react-app are no longer supported …

原因是create-react-app腳手架版本過低,需要升級到最新

解決辦法:刪除舊版本安裝新版本create-react-app

1、刪除舊版

     sudo npm uninstall -g create-react-app

2、重新安裝

	sudo npm install -g create-react-app
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章