浏览了一下官网的安装流程,发现需要安装的有点多,所以感觉有必要纪录一下。
我选择平台是ios(swift)+mac:
把 React Native 组件集成到 iOS 应用中有如下几个主要步骤:
搭建开发环境
必须安装的依赖有:Node、Watchman、Xcode 和 CocoaPods。
# 安装node
brew install node
# 安装watchman
brew install watchman
# 使用nrm工具切换淘宝源
npx nrm use taobao
# 安装Yarn
npm install -g yarn
# 安装cocoapods
brew install cocoapods