NPM修改镜像源为最新淘宝镜像
NPM修改镜像源为淘宝镜像
默认的npm镜像地址在国外,有时网络波动,导致依赖无法加载
临时引用
npm install --registry=https://registry.npmmirror.com/
全局修改
npm config set registry https://registry.npmmirror.com/
npm config set disturl https://npmmirror.com/dist
yarn config set registry https://registry.npmmirror.com/
yarn config set disturl https://npmmirror.com/dist
验证
npm config get registry
删除
npm config delete registrynpm config delete disturl
- 感谢你赐予我前进的力量
                        
                        
                            
赞赏者名单
                            因为你们的支持让我意识到写文章的价值🙏
                        
                    
            本文是原创文章,采用 CC BY-NC-ND 4.0 协议,完整转载请注明来自 木子李
        
     评论
            
                匿名评论
                隐私政策
            
            
                你无需删除空行,直接评论以获取最佳展示效果
            
         
            
        

 
                         
                 
             
            