Article From:

node.js Once installed successfully, both input node-v and npm-v can return version information, but the execution of the NPM install command will report an error. The following figure, why?

Answer 0:

npmIt’s slower to visit in China, you know why.
It is recommended to use the following operations:
npm config set registry

It is not recommended to use cnpm, sometimes it may lead to a strange bug.

Answer 1:

Try cnpm

Answer 2:

Because NPM is too slow in China, it is recommended to register cnpm command.
npm install -g cnpm –registry=

After that, NPM can be replaced by cnpm.

Leave a Reply

Your email address will not be published. Required fields are marked *