C:\Users\v_xbingtan>npm install xml2js -g
npm ERR! code ETIMEDOUT
npm ERR! errno ETIMEDOUT
npm ERR! network request to http://registry.npmjs.org/xml2js failed, reason: con
nect ETIMEDOUT 151.101.72.162:80
npm ERR! network This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settin
gs.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly. See: 'npm help config'
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\v_xbingtan\AppData\Roaming\npm-cache_logs\2017-08-23T01_5
4_44_228Z-debug.log
npm -v , node -v 都没问题,说明都安装上了,但是现在
只要是安装第三方模块就报上面的错,cnpmp也不能装,卸载重装也是这样,然后修改
registry,设置proxy为空什么的都试过了,没用,刚学nodejs,好几天都卡在这了,有没有谁碰到过,到底是什么原因,有没有好的解决办法,求教
mac么 修改了配置文件之后 需要source profile
你现在的错误是网络连接不上 如果在公司可以找你们网络管理员要个代理
在家的话 如果浏览器能访问这个地址 那么清掉配置文件之后就能访问了
我这边是用“npm install -g npm ”解决的,转自https://blog.csdn.net/m0_37323771/article/details/81194952,
你也可以看看https://www.jianshu.com/p/d65f8c79d85c