Home > Article > Web Front-end > Methods to solve the package management tool NPM and yarn download and installation timeout
npm install -g cnpm --registry=https://registry.npm.taobao.org
npm config set registry https://registry.npm.taobao.org
In this way, the npm command can be replaced by the cnpm command, such as when using the react scaffolding command A timeout error will be reported when create-react-app
, this setting can solve the problem. [Video tutorial recommendation: nodejs video tutorial]
yarn config set registry https://registry.npm.taobao.org
Using the react scaffolding commandcreate-react -Timeout error reported when app
:
There appears to be trouble with your network connection. Retrying…
It can be solved after the setting is completed.
For more programming-related knowledge, please visit: Introduction to Programming! !
The above is the detailed content of Methods to solve the package management tool NPM and yarn download and installation timeout. For more information, please follow other related articles on the PHP Chinese website!