ReactNative本機環境配置
阿新 • • 發佈:2019-02-19
ReactNative 簡介
ReactNative 於2015年被 Facebook 開源。
基於 JavaScript ,動態載入並編譯Virtual-DOM,可同時運行於Android、iOS、Browser各個平臺。
在Android上依賴於webkit.org官方開源的jsc.so。
ReactNative 環境配置
下面只介紹 macOS 開發平臺下的 Android 環境配置 [參考ReactNative環境搭建]
* 安裝 HomeBrew, Mac 系統的包管理器
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
* 安裝 Node.js, JavaScript 的執行環境
brew install node
* 設定 npm 映象以加速, npm 是 Node.js 的模組依賴管理工具
npm config set registry https://registry.npm.taobao.org --global
npm config set disturl https://npm.taobao.org/dist --global
* 安裝 react-native-cli, ReactNative 的命令列工具
npm install -g react-native-cli
* 安裝 watchman, 監視檔案系統變更的工具
brew install watchman