laravel项目中通过nvmw安装node.js和npm 开发环境-- windows版

时间:2022-02-07 03:25:49

windows版本安装

此教程执行的时候,网速一定要好。不然可能出现各种错误。

如果本文对你有用,请爱心点个赞,提高排名,帮助更多的人。谢谢大家!❤

git clone nvmw 


  • 直接从 github clone nvmw 到项目目录中,本人是用的laravel,本地的路径为E:\wamp64\www\Taskmanager这里建议大家都使用 项目目录存放。
cd Taskmanager
git clone https://github.com/mengyilingjian/nvmw.git
  • 把E:\wamp64\www\Taskmanager\nvmw设置到系统环境变量中,如下图:

laravel项目中通过nvmw安装node.js和npm 开发环境-- windows版

  • 重新打开终端输入 nvmw,会显示nvmw的参数信息如下:
Node Version Manager for Windows

Usage:
nvmw help Show this message
nvmw install [version] [arch] Download and install a [version]
for [arch] architecture (optional)
nvmw uninstall [version] Uninstall a [version]
nvmw use [version] Modify PATH to use [version]
nvmw ls List installed versions Example:
nvmw install v0.10.21 Install a specific version number of node.js
nvmw use v0.10.21 Use the specific version
nvmw install iojs Install the latest version of io.js
nvmw install iojs-v1.0.2 Install a specific version number of io.js
nvmw use iojs-v1.0.2 Use the specific version io.js nvmw install v0.10.35 x86 Install a 32-bit version

通过nvmw安装任意版本的node


nvmw install v8.11.4
  • 下载过程中会依次安装node.js和npm,安装完成后会显示下图信息:

laravel项目中通过nvmw安装node.js和npm 开发环境-- windows版

  • 安装完成后,nvmw目录中将多出一个v.8.11.4目录,将这个目录也添加进系统环境变量中。重新启动终端,通过命令 node -v和npm -v 查看安装版本号。

laravel项目中通过nvmw安装node.js和npm 开发环境-- windows版

  • 为了方便后续使用nmp安装快速,可设置淘宝镜像
npm -config set registry "https://registry.npm.taobao.org"

如果安装成功,请给个start⭐:https://github.com/mengyilingjian/nvmw,如果安装不成功,请进群联系我,或者添加我的微信:mengyilingjian,添加时请备注,谢谢!

laravel项目中通过nvmw安装node.js和npm 开发环境-- windows版