Angular应用安装错误:"...//registry.npmjs.org/"附近解析时,JSON输入意外结束 [英] Angular app installing Error: Unexpected end of JSON input while parsing near '...//registry.npmjs.org/'

查看:80
本文介绍了Angular应用安装错误:"...//registry.npmjs.org/"附近解析时,JSON输入意外结束的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对Angular非常陌生.我已经使用以下命令安装了Angular:

I am very new to Angular. I have installed the Angular by using the command:

npm install -g @angular/cli

当我检查Angular的版本时,它显示:

When I check the version of Angular it shows:

之后,我使用ng new newApp

在安装应用程序时出现错误:

I have got an error during app installation:

在解析附近时JSON输入意外结束 '...//registry.npmjs.org/'

Unexpected end of JSON input while parsing near '...//registry.npmjs.org/'

这是我所做的事情的图像:

Here is the image of what I have done:

您可以通过以下链接找到日志内容: https://drive.google.com/file/d/11MEWOcSaU4c-1879LuijRiXRvCu-cAIz/view?usp = sharing

You can find log content through this link: https://drive.google.com/file/d/11MEWOcSaU4c-1879LuijRiXRvCu-cAIz/view?usp=sharing

让我知道问题出在哪里...

Let me know where is the problem...

推荐答案

首先尝试使用以下命令清除npm缓存,然后尝试创建新的ng应用程序

Try clearing the npm cache first using the following command and then try creating a new ng application

npm cache clean --force

这篇关于Angular应用安装错误:"...//registry.npmjs.org/"附近解析时,JSON输入意外结束的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆