官网下载地址:https://nodejs.org/en/download/
下载完直接安装即可,注意配置环境,这里不过多赘述。
//cmd命令验证是否安装配置成功
C:\Users\Administrator>node -v
v18.16.0
C:\Users\Administrator>npm -v
9.5.1
C:\Users\Administrator>npm install -g cnpm --registry=https://registry.npm.taobao.org
npm WARN deprecated @npmcli/move-file@2.0.1: This functionality has been moved to @npmcli/fs
added 469 packages in 13s
27 packages are looking for funding
run `npm fund` for details
npm notice
npm notice New minor version of npm available! 9.5.1 -> 9.6.6
npm notice Changelog: https://github.com/npm/cli/releases/tag/v9.6.6
npm notice Run npm install -g npm@9.6.6 to update!
npm notice
C:\Users\Administrator>npm install -g npm@9.6.6
added 1 package in 4s
C:\Users\Administrator>cnpm config get registry
https://registry.npmmirror.com/
C:\Users\Administrator>cnpm install -g @vue/cli
vue -V
或 vue --version
C:\Users\Administrator>vue --version
@vue/cli 5.0.8
C:\Users\Administrator>vue ui
Starting GUI...
Ready on http://localhost:8000
npm run serve
D:\demo\test>npm run serve
> test@0.1.0 serve
> vue-cli-service serve
INFO Starting development server...
DONE Compiled successfully in 1481ms
App running at:
- Local: http://localhost:8080/
- Network: http://192.168.2.124:8080/
Note that the development build is not optimized.
To create a production build, run npm run build.