用yarn install 时候 报
yarn install v1.22.21
[1/4] Resolving packages...
[2/4] Fetching packages...
info There appears to be trouble with your network connection. Retrying...
info There appears to be trouble with your network connection. Retrying...
info There appears to be trouble with your network connection. Retrying...
info There appears to be trouble with your network connection. Retrying...
error Error: connect ETIMEDOUT 104.16.24.34:443
at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1278:16)
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
将strict-ssl设置为false yarn config set strict-ssl false 重新运行还是会报同样的错
百度了一下看到网上说
把node-sass镜像源进行设置成国内的
yarn config set sass-binary-site http://npm.taobao.org/mirrors/node-sass
然后将资源地址设置为淘宝镜像
yarn config set registry https://registry.npm.taobao.org/
查看设置项
yarn config get registry
如下
再次yarn install 成功了