Node's npm has been wrong.

Source: Internet
Author: User

Recently installed NODE,NPM has been unsuccessful, finally found a long time to find a solution, reference

Workaround:

Delete the NPMRC file.

Using mirroring

Image use Method (three ways any one can solve the problem, we recommend the use of a third, the configuration is dead, the next time the configuration is still in):

1. Through the config command

12 npm config set registry http://registry.cnpmjs.orgnpm info underscore (如果上面配置正确这个命令会有字符串response)

2. Command line designation

1 npm --registry http://registry.cnpmjs.org info underscore

3. Edit ~/.npmrc Add to the content below

1 registry = http://registry.cnpmjs.org

 

But I just deleted the NPMRC file.

Many times the NPM configuration is not successful primarily as a path problem

If I delete this NPMRC file, I will reconfigure the path or error

NPM config set prefix "C:\Program files\nodejs\node_global"
And
NPM config set cache "C:\Program files\nodejs\node_cache"

This is still a mistake.

So I was simply to remove the NPMRC file directly again, by default with the path of the system

C:\Users\Administrator\AppData\Roaming\npm\node_modules

The environment variable is then added to the Node_path where the path is done.

I haven't found any problems for the time being.

Node's npm has been wrong.

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.