繁体   English   中英

反应,创建项目问题

[英]react, creating a project issues

我正在创建如下所示的反应应用程序,但我发现了一个错误。请指导我是什么错误。

E:\React>create-react-app template-app

Creating a new React app in E:\React\template-app.

Installing packages. This might take a couple of minutes.
Installing react, react-dom, and react-scripts with cra-template...

npm ERR! Unexpected end of JSON input while parsing near '...pha.24","dependencies'

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Muaaz\AppData\Roaming\npm-cache\_logs\2020-08-24T11_52_18_657Z-debug.log

Aborting installation.
  npm install --save --save-exact --loglevel error react react-dom react-scripts cra-template has failed.

Deleting generated file... package.json
Deleting template-app/ from E:\React
Done.

对于这种事情,值得检查相关 GitHub 存储库上的问题。 问题 #7261来看,似乎其他人不时遇到这个问题,并运行它为他们修复了它:

npm cache clean --force

暂无
暂无

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

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