国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

建立 nuxt3 項(xiàng)目時(shí)發(fā)生錯(cuò)誤。無(wú)法從登錄下載模板
P粉469090753
P粉469090753 2023-11-01 23:50:03
0
2
1152

當(dāng)我使用此命令建立新的 Nuxt 3 專案時(shí):

npx nuxi init nuxt-app

它輸出此錯(cuò)誤:

ERROR  (node:1752) ExperimentalWarning: The Fetch API is an experimental feature. This feature could change at any time                         09:53:25
(Use `node --trace-warnings ...` to show where the warning was created)


 ERROR  Failed to download template from registry: fetch failed                                                                                  09:53:25

  at /C:/Users/myname/AppData/Local/npm-cache/_npx/a95e0f536cf9a537/node_modules/nuxi/dist/chunks/init.mjs:13269:11
  at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
  at async downloadTemplate (/C:/Users/myname/AppData/Local/npm-cache/_npx/a95e0f536cf9a537/node_modules/nuxi/dist/chunks/init.mjs:13268:20)
  at async Object.invoke (/C:/Users/myname/AppData/Local/npm-cache/_npx/a95e0f536cf9a537/node_modules/nuxi/dist/chunks/init.mjs:13336:15)
  at async _main (/C:/Users/myname/AppData/Local/npm-cache/_npx/a95e0f536cf9a537/node_modules/nuxi/dist/cli.mjs:50:20)

我的環(huán)境:

  • 作業(yè)系統(tǒng):Windows 11
  • 節(jié)點(diǎn)版本:18.12.0
  • #
  • npm 版本:8.12.1

起初我懷疑這是由於我的網(wǎng)路造成的。但是當(dāng)我嘗試安裝其他 npm 套件時(shí)沒有收到錯(cuò)誤。

P粉469090753
P粉469090753

全部回覆(2)
P粉287345251

我也遇到了同樣的錯(cuò)誤(Windows 10)。我的很簡(jiǎn)單。

ERROR  Error: Failed to download template from registry: fetch failed

是的,這與網(wǎng)路或IP被封鎖有關(guān)。不過我還是設(shè)法解決了。這就是我所做的。

先進(jìn)入C:\Windows\System32\drivers\etc

#在此資料夾中尋找「hosts」檔案。用記事本以管理員身份開啟?,F(xiàn)在在文件末尾(以及其他 IP 位址)添加此行。

// Some other ip address
185.199.108.133 raw.githubusercontent.com

這應(yīng)該可以解決問題。

P粉633075725

我在這裡找到了原因。

確實(shí)是網(wǎng)路問題。它無(wú)法從命令列存取 raw.githubusercontent.com,因?yàn)樗也坏较鄳?yīng)的 IP 位址。

raw.githubusercontent.com 的正確 IP 位址新增至 Windows 主機(jī)檔案後,問題已修正

最新下載
更多>
網(wǎng)站特效
網(wǎng)站源碼
網(wǎng)站素材
前端模板