依据官方的文档
npx nuxi init nuxt-app
但是会发现会报以下的错误,挂机场后也无用,或者指定了raw.githubusercontent.com ip也没用
![](https://img.haomeiwen.com/i1932840/1cf26bd7a1cc5a18.png)
但是我们会发现,错误的提示中有个链接
https://raw.githubusercontent.com/nuxt/starter/templates/templates/v3.json
直接打开后,我们会发现
{
"name": "v3",
"defaultDir": "nuxt-app",
"url": "https://v3.nuxtjs.org",
"tar": "https://codeload.github.com/nuxt/starter/tar.gz/refs/heads/v3"
}
这个 tar 下的 链接很可疑,tar(压缩),codeload(代码下载)
尝试打开一下 https://codeload.github.com/nuxt/starter/tar.gz/refs/heads/v3
一个压缩包就下载下来了,starter-3.tar.gz
tar -zxvf starter-3.tar.gz
cd starter-3
![](https://img.haomeiwen.com/i1932840/e7b6764f6970a429.png)
有了package.json,那么接下来就是常规的操作了,yarn or npm 均可
网友评论