I create an application with react-native-cli, how can I install it to my Android phone?
(Although in development mode)
Platform: osX(10.12+) target deployment: Android Phone (v6.0+)
There is an easy way with Terminal.
in development mode, we run application in android studio emulator or expo or gnymotion with a simple command:
react-native run-android
this time before running this command, run:
adb devices
this command will return all of the devices(include android studio emulator) with an id and name.
first, active: USB debugging option in your android phone then connect your phone to the computer with USB cable
now run adb devices on the terminal. note that react-native run-android command will install your application on one device that exists in adb devices list. so close all other android emulator and then run again adb devices for checking all devices connected to this computer.
now simply run below command and wait for installing it on the device.
react-native run-android
this will install the application on your connected phone.