报错信息gyp ERR! find VS:stack Error: Could not find any Visual Studio installation to use 指向编译错误
原因
npm 指向淘宝镜像,有的话会不全或者没有的问题
解决办法
在终端输入npm config list,输出中查找user-agent =字段,查看信息是否为指向淘宝镜像,
修改字段
npm config set registry="https://registry.npmjs.org/"
重新下载就成功了
npm install -g @vue/cli