[Pit Condition]--windows Upgrade Node Latest version error "NPM install-g n"

Source: Internet
Author: User

I was to download a vue-cli, and then the technology changed rapidly, told me to first upgrade my node to more than 8 (currently v6.1.13)

Upgrade on upgrade, update error

    1. Try the first method, one of the most popular methods on the Web, and the most successful one (if I succeed, I don't need to write this article)
1 1. The first step2 npm-g Install n3 2. Step Two4 N Stable (update to latest stable version)5 6 Common commands included7 N//Will list all installed versions for you to switch8 9 N Latest//install the latest versionTen  One N Stable//install the latest stable version A  - n LTS//Install the latest long-term support version -  the n RM [version number]//delete a version -  -N-h//help command

If you quote such a mistake

Then run it like this.

NPM install-g N--force

If this error is reported after running

I clear the cache and try again

So congratulations on most of the methods you can use, you can't ~ ~ ~ (Thorn not exciting)

Anyway, I still haven't found a reason.

If this method is not possible, I personally recommend downloading the latest stable version from the official website and then overwrite the installation ... (I take the test)

Come on, let's go through the node installation process.

Tell you what, Mimi, before overwriting, check the path where node is installed: where node

Desperate, I actually installed on the C drive.

After overwriting the installation, check the environment variables

Then run Node-v

Very nice.

[Pit Condition]--windows Upgrade Node Latest version error "NPM install-g n"

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.