React Starwars数据库快速入门与部署指南

Create React App入门

本项目是通过 Create React App 构建的。可以使用以下脚本来管理项目:

开发环境

  • npm start:在开发模式下运行应用程序。打开浏览器可以查看效果。编辑代码后页面将自动重新加载,并且控制台会显示任何Linting错误。

测试

  • npm test:启动交互式监视模式下的测试运行器,方便在开发中查看测试反馈。

构建生产环境

  • npm run build:构建应用程序以用于生产环境。此命令将生成一个优化后的 build 文件夹,捆绑应用以确保最佳性能。构建文件经过最小化处理,文件名包含哈希,便于部署。

Eject操作

  • npm run eject:这是单向操作!如果对当前配置不满意,可随时运行 eject 命令。该操作会将所有配置文件和依赖项(如 WebpackBabel)提取到项目中,以便进一步调整。

有关更多信息,请查阅 关于 部分。

zip
react-star-db-main.zip 预估大小:42个文件
folder
react-star-db-main 文件夹
file
package.json 810B
file
package-lock.json 670KB
folder
src 文件夹
file
index.js 155B
folder
components 文件夹
folder
person-details 文件夹
file
person-details.js 2KB
file
index.js 75B
file
person-details.css 322B
folder
error-indicator 文件夹
file
death-star.png 6KB
file
index.js 78B
file
error-indicator.css 230B
file
error-indicator.js 568B
folder
starship-details 文件夹
file
index.js 81B
folder
starship-details.css 文件夹
file
starship-details.js 95B
folder
planet-details 文件夹
file
index.js 75B
file
planet-details.js 91B
folder
planet-details.css 文件夹
folder
people-page 文件夹
file
index.js 66B
file
people-page.js 1KB
folder
people-page.css 文件夹
folder
app 文件夹
folder
app.css 文件夹
file
index.js 44B
file
app.js 2KB
folder
item-list 文件夹
file
index.js 60B
file
item-list.js 829B
file
item-list.css 165B
folder
random-planet 文件夹
file
index.js 72B
file
random-planet.css 424B
file
random-planet.js 2KB
folder
button 文件夹
file
button.css 35B
file
index.js 53B
file
button.js 249B
folder
header 文件夹
file
index.js 53B
file
header.css 376B
file
header.js 465B
folder
spinner 文件夹
file
index.js 56B
file
spinner.css 52B
file
spinner.svg 1KB
file
spinner.js 221B
folder
services 文件夹
file
swapi-service.js 2KB
file
.gitignore 310B
folder
public 文件夹
file
index.html 499B
file
README.md 3KB
zip 文件大小:186.35KB