window 11安装Vue前端运行环境 https://www.jianshu.com/p/f40458d99fa0
window 7安装Vue前端运行环境 https://www.jianshu.com/p/e575f89c5e9e
1、下载nvm
在github里直接搜nvm,找到nvm的下载路径
https://github.com/nvm-sh/nvm
2、安装nvm
点击链接进入页面,找到curl和wget下载方式的链接,选择任一下载方式:
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.4/install.sh | bash
wget -qO- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.4/install.sh | bash
3、添加环境变量
vi .bashrc
export NVM_DIR="$([ -z "${XDG_CONFIG_HOME-}" ] && printf %s "${HOME}/.nvm" || printf %s "${XDG_CONFIG_HOME}/nvm")"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
4、安装node
nvm install node

安装最新版本的node
5、使用新安装的nodejs
nvm use node

使用node
6、安装vue
6.1、查看npm的镜像源
npm config get registry
是国内的镜像源,可以直接使用

npm的镜像源
下面为国内可用的镜像源地址
1. 更换国内源
npm config set registry https://registry.npmjs.org/
2. 更换淘宝镜像
npm config set registry https://registry.npm.taobao.org
6.2、关闭镜像地址的https证书校验
npm config set strict-ssl false
6.3、安装vue
npm install -g @vue/cli
vue -V

vue安装成功