Today, NPM install always reports an error: unable to verify the first certificate. After checking, it is found that
As of February 27, 2014, npm no longer supports its self-signed certificates.
On February 27, 2014, NPM no longer supported self signed certificates
Because NPM install follows the HTTPS protocol, it needs to be guaranteed by digital certificates
Solution 1:
Cancel SSL validation: NPM config set strict SSL false
If not, replace the NPM source with a domestic image:
NPM config set registry http://registry.cnpmjs.org/
npm config set registry http://registry.npm.taobao.org/
Solution 2:
Upgrade: NPM install NPM – G — Ca = null
or NPM config set CA = “”
Recommended usage 1
Similar Posts:
- NPM err installation dependency package error [How to Solve]
- Error message encountered in new Vue project
- The yarn node sass installation reported an error
- [Solved] Vue create Create Project Error: command failed: npm install –loglevel error
- Solutions to the problem that image webpack loader cannot be installed or the installation is stuck
- NPM err windows appears in NPM under win7_ NT 6.1.7601 error handling method
- [Solved] JSON check syntax error: json.decoder.JSONDecodeError: Invalid control character at: line 1 column
- Summary of 5 error reports encountered during Vue installation
- [Solved] Docker npm install: npm ERR! code UNABLE_TO_GET_ISSUER_CERT_LOCALLY.. reason: unable to get local issuer certificate
- NPM Error: npm ERR! 426 Upgrade Required [How to Solve]