Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to change the version of nodejs

2025-02-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/02 Report--

This article introduces the knowledge of "how to change the version of nodejs". In the operation of actual cases, many people will encounter such a dilemma. Then let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!

Change methods: 1, the use of nvm tools, the implementation of the "nvm install specified version number" command can be switched to the specified version, "nvm install lastest" command can be upgraded to the latest version; 2, the use of Node Binary management module, the implementation of the "n specified version number" command can be switched to the specified version.

This tutorial operating environment: linux5.9.8 system, nodejs version 12.19.0, DELL G3 computer.

Sometimes we need to be forced to upgrade or downgrade the version of nodejs, and then the problem arises. How to do it? summed up below, there are two ways to change the version of nodejs. Nvm and n are both version management libraries of nodejs and can be used to look at personal habits.

Method 1. Use the nvm tool

1), switch to the specified version

Nvm install specifies the version number

2) upgrade to the latest version

Nvm install lastest

3) upgrade to stable version

Nvm install stable

Method 2: use the n tool

The Node Binary management module "n" can manage your Node version in a very simple way

1), modified version

N specify version number

2) upgrade to the latest stable version

N stable

3) upgrade to the latest version

This is the end of n latest's "how to change the version of nodejs". Thank you for reading. If you want to know more about the industry, you can follow the website, the editor will output more high-quality practical articles for you!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report