Update RunningOnDeviceAndroid.md

This commit is contained in:
Martin Konicek 2015-10-31 17:13:32 +00:00
parent d98d4e6952
commit 7ae39f83ac
1 changed files with 9 additions and 8 deletions

View File

@ -30,11 +30,12 @@ Have your device connected via USB with debugging enabled (see paragraph above o
### Configure your app to connect to the local dev server via Wi-Fi ### Configure your app to connect to the local dev server via Wi-Fi
1. Make sure your laptop and your phone are on the same Wi-Fi network. Make sure your laptop and your phone are on the **same Wi-Fi network**.
2. Open your React Native app on your device.
3. You'll see a red screen with an error. This is OK. The following steps will fix that. 1. Open your React Native app on your device.
4. Open the **Developer menu** by shaking the device or running `adb shell input keyevent 82` from the command line. 2. You'll see a red screen with an error. This is OK. The following steps will fix that.
5. Go to `Dev Settings`. 3. Open the **Developer menu** by shaking the device or running `adb shell input keyevent 82` from the command line.
6. Go to `Debug server host for device`. 4. Go to `Dev Settings`.
7. Type in your machine's IP address and the port of the local dev server (e.g. 10.0.1.1:8081). **On Mac**, you can find the IP address in System Preferences / Network. **On Windows**, open the command prompt and type `ipconfig` to find your machine's IP address ([more info](http://windows.microsoft.com/en-us/windows/using-command-line-tools-networking-information)). 5. Go to `Debug server host for device`.
8. Go back to the **Developer menu** and select `Reload JS`. 6. Type in your machine's IP address and the port of the local dev server (e.g. 10.0.1.1:8081). **On Mac**, you can find the IP address in System Preferences / Network. **On Windows**, open the command prompt and type `ipconfig` to find your machine's IP address ([more info](http://windows.microsoft.com/en-us/windows/using-command-line-tools-networking-information)).
7. Go back to the **Developer menu** and select `Reload JS`.