繁体   English   中英

我在创建 React 应用程序时遇到以下问题

[英]I am facing the issue below while creating a React app

PS F:\Programming Tutorials Videos\R Practice> npx create-react-app custom-hook
npm ERR! code ENOTFOUND
npm ERR! syscall getaddrinfo
npm ERR! errno ENOTFOUND
npm ERR! network request to https://registry.npmjs.org/create-react-app failed, reason: getaddrinfo ENOTFOUND registry.npmjs.org
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\GALAXY COMPUTERS\AppData\Local\npm-cache\_logs\2023-01-06T17_33_28_552Z-debug-0.logtype here

我已经安装了 node.js 最新版本,但问题仍然存在并且使用 inte.net Connection 我创建了 React App 为什么会这样,当我没有连接到 Inte.net 时它不会创建 React App

当您将create-react-appnpx命令一起使用时,它会连接到 your.network 并创建需要安装依赖项的新项目,您的项目依赖这些依赖项,例如reactreact-dom等,因此它需要.network 连接。

暂无
暂无

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

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