- Homebrew
brew install nvm
nvm install 5.0
brew install watchman
npm install
-
download Android jdk
-
Install Android
sdk
:brew install android-sdk
-
Add
export ANDROID_HOME=/usr/local/opt/android-sdk
to~/.bash_profile
-
brew install gradle
-
touch ~/.gradle/gradle.properties && echo "org.gradle.daemon=true" >> ~/.gradle/gradle.properties
-
Run
android
and install
- Android SDK Build-tools version 23.0.2
- Android 6.0 (API 23)
- Intel x86 Atom System Image
- from Extras install
- Android Support Repository
- Google Play Services
- Intel x86 Emulator Accelerator (HAXM installer)
- Setup Accelerator:
- $ANDROID_HOME/extras/intel/Hardware_Accelerated_Execution_Manager/silent_install.sh
- verify it's working: after running
kextstat | grep intel
you should seecom.intel.kext.intelhaxm
- Add Andorid Virtual Device by running
android avd
and filling form with:
- name: badgerreact
- target: Google APIs 6.0, api level 23
- CPU/ABI: Google APIs Intel Atom (x86)
- skin: no skin
- RAM: 2024
- Use Host GPU: checked
- Xcode
open ios/BadgerReact.xcodeproj
- Hit
cmd
+R
- run
emulator -avd badgerreact
You should seeHAXM is working and emulator runs in fast virt mode
- in other tab run
react-native run-android
- if you have problems with fetching bundle - shake device, go to Dev Settings and set up dev server ip and port
- Run
npm run logs
to see your app's logs
Is here