簡體   English   中英

我在使用 npx-create-reat-app 創建我的 React 應用程序時遇到問題

[英]i'm having issues creating my React app using npx-create-reat-app

$ npx create-react-app 機器人 npx:在 583.936 秒內安裝了 67 個

在 C:\Users\User\ReactApps\robot 中創建一個新的 React 應用程序。

安裝軟件包。 這可能需要幾分鍾。 使用 cra-template 安裝 react、react-dom 和 react-scripts...

npm 錯誤! 代碼 ECONNRESET npm 錯誤! errno ECONNRESET npm 錯誤! https://registry.npmjs.org/querystring/-/querystring-0.2.0.tgz的網絡請求失敗,原因:套接字掛起 npm ERR。 網絡 這是與網絡連接有關的問題。 npm ERR,網絡 在大多數情況下,您使用代理服務器或網絡設置錯誤。 npm ERR:網絡 npm ERR! 網絡 如果您在代理后面,請確保 npm ERR! 網絡“代理”配置設置正確。 請參閱:'npm 幫助配置'

npm ERR:此運行的完整日志可在以下位置找到:npm ERR。 C:\Users\User\AppData\Roaming\npm-cache_logs\2021-01-21T18_37_39_680Z-debug.log

中止安裝。 npm install --save --save-exact --loglevel 錯誤 react-dom react-scripts cra-template 失敗。

正在刪除生成的文件... package.json 刪除機器人/從 C:\Users\User\ReactApps 完成。

檢查這個希望你創建反應應用程序

1 檢查你的 nodejs 版本

node -v

2 檢查你的 npm 版本

npm -v

3.你全局安裝了你的 react 應用

4.Go終端和根路徑

npx create-react-app appname
  1. 卸載 [nodejs] ( https://nodejs.org/en/download/ )!
  2. 重新安裝

它有效我已經嘗試過了。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM