Update Node.js

The method to update node.js .

Posted by Dusign on 2019-12-20
Words 90 and Reading Time 1 Minutes
Viewed Times
  1. 清除 npm 缓存
    npm cache clean -f

  2. 安装 n 模块,n 模块是专门用来管理 nodejs 的版本的
    sudo npm install -g n

  3. 查看 n 模块的版本
    n -V

  4. 升级到稳定版
    n stable

  5. 升级到指定版本
    n [版本号]

  6. n 模块适用于 linux 或 mac,windows 下使用 nvmnodist 对 node.js 或 npm进行版本管理。


If you like this blog or find it useful for you, you are welcome to comment on it. You are also welcome to share this blog, so that more people can participate in it. If the images used in the blog infringe your copyright, please contact the author to delete them. Thank you !

...

...

00:00
00:00