mac下搭建react-native环境

时间:2022-07-15 18:52:49

1.安装Homebrew

mac下搭建react-native环境

2.安装node(最好安装4.x以上版本这样就自带了一个npm)

mac下搭建react-native环境

3.安装npm(node的包管理工具)

一般高版本的npm在安装node的时候已经具有了

4.安装react-native

mac下搭建react-native环境

5.生成测试项目

mac下搭建react-native环境

6.cd到项目文件目录AwesomeProject 然后开启rn本地服务 命令行为: sudo react-native start