欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

react - 脚手架

程序员文章站 2024-02-26 21:03:22
...

1.安装脚手架前需要安装node,npm

2. 全局安装react 脚手架

 npm install create-react-app -g

3. 利用脚手架创建项目

create-react-app react_project

4. 启动项目

# npm 
npm run start

# yarn
yarn start

5. 默认监听端口为3000

http://localhost:3000/