关于javascript:React项目搭建

3次阅读

共计 305 个字符,预计需要花费 1 分钟才能阅读完成。

1. 全局装置脚手架

npm install -g create-react-app

2、创立我的项目,装置依赖

create-react-app my-react-app

3、进入我的项目

cd my-react-app

4、启动我的项目

npm start

5. 首先装置路由组件:react-router-dom

npm install react-router-dom –save-dev

6. 装置 redux 的第三方模块:

npm install redux –save

npm install react-redux –save

7. 装置 axios

npm i axios –s

8. 装置 antd

npm i antd –s

9. 装置 sass
npm node-sass -D

正文完
 0