简体   繁体   English

创建VueJS项目后运行npm安装报错

[英]Error occurs when running npm install after creating VueJS project

I just installed VueJS and I tried creating a project.我刚刚安装了 VueJS,并尝试创建一个项目。 I followed their installation and quick start guide VueJS Getting Started.我遵循了他们的安装和快速入门指南VueJS Getting Started。

> npm init vue@latest

> cd (My Project Name Here)

> npm install

However, after doing > npm install , it returns the following message in the VSCode Terminal:但是,在执行> npm install之后,它会在 VSCode 终端中返回以下消息:

npm ERR! code ERR_SOCKET_TIMEOUT
npm ERR! errno ERR_SOCKET_TIMEOUT
npm ERR! network Invalid response body while trying to fetch https://registry.npmjs.org/lodash: Socket timeout
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 settings.
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\alscg\AppData\Local\npm-cache\_logs\2022-04-07T08_54_47_537Z-debug-0.log

How do I fix this?我该如何解决? Am I doing this wrong?我做错了吗?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM