一、环境搭建
1. 系统要求
- macOS: 支持 Intel 和 Apple Silicon 芯片
- Windows: 10 或更高版本
- Linux: Ubuntu 18.04 或更高版本
2. 安装 Node.js
推荐使用 LTS 版本 (16.x 或更高):
# 使用 nvm (推荐)
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | bash
nvm install --lts
nvm use --lts
# 或直接安装
# Windows: 从 https://nodejs.org/ 下载安装包
# Mac: brew install node
3. 安装 Java Development Kit (JDK)
React Native 需要 JDK 11: