reactjs - React.js localhost 拒绝连接
问题描述
我已经离开了我的 react 项目一段时间,它工作正常,但是当我回到它并在 chrome 上运行时,它给出了一个 localhost 拒绝连接页面,我不知道为什么。
我看到一篇帖子说要下载扩展 Live Server,但是,它只是打开一个包含编写代码的页面,而不是运行它。
这是我运行调试器时自动创建的 launch.json,
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "pwa-chrome",
"request": "launch",
"name": "Launch Chrome against localhost",
"url": "http://localhost:8080",
"webRoot": "${workspaceFolder}"
}
]
}
任何建议都会很棒,谢谢
解决方案
推荐阅读
- python - Python 装饰器早期解析破坏了前向声明
- powershell - 如何调用在 for 循环中创建的变量?
- sql-server - SQL Server 中具有空值多列的平均值
- firebase - 在 Flutter 中返回 Null 的可调用云函数
- amazon-web-services - 如何确定使用 AWS Terraform 资源所需的 AWS IAM 策略权限?
- java - 即使使用@JsonInclude(JsonInclude.Include.NON_EMPTY),当所有属性都为空或为空时,如何防止空复杂对象?
- flask - Flask-SQLAlchemy 通过一个查询获取带有子代的父代
- c# - 类型化 HttpClient 与 IHttpClientFactory
- amazon-web-services - S3 同步与跨区域复制
- amazon-emr - AWS 采用并行状态来编排 EMR 作业