Update node.js to the latest version under mac

青灯夜游
Release: 2021-01-08 18:44:57
forward
4692 people have browsed it

How to upgrade

nodejsto the latest version undermac? The following article will introduce the method to you. It has certain reference value. Friends in need can refer to it. I hope it will be helpful to everyone.

Update node.js to the latest version under mac

Related recommendations: "nodejs video tutorial"

Upgrade node.js under mac

The first step, check the current version

node -v
Copy after login
Copy after login

The second step, clear the cache of node.js:

sudo npm cache clean -f
Copy after login

The third step, install the node.js version Management tool, n, his name is n

sudo npm install -g n
Copy after login

The fourth step is to install the latest stable version

sudo n stable
Copy after login

The fifth step is to check the updated version

node -v
Copy after login
Copy after login

Step 6: Update the npm version

sudo npm install npm@latest -g
Copy after login

For more programming-related knowledge, please visit:Programming Teaching! !

The above is the detailed content of Update node.js to the latest version under mac. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:csdn.net
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!