I used Google Nexus 5 - 4.4.0 emulator Genymotion.
Running this:
import Reactotron from 'reactotron'
Reactotron.connect()
Won't connect.
Is there any criteria I missed?
Try this:
[Android 4.x] Use 10.0.3.2 instead of localhost on Genymotion:
import Reactotron from 'reactotron'
Reactotron.connect({
server: '10.0.3.2', // for Genymotion
port: 3334,
enabled: true
})
[Android 5.0+] just run command:
$ adb reverse tcp:3334 tcp:3334
Ya, on Android 4.x, it doesn't know how to reach back to your computer. Like @jhen0409 said, you'll have to enter your IP address just like you did for your packager. Thanks @jhen0409.
Is that IP always 10.0.3.2 for Genymotion?
Is that IP always 10.0.3.2 for Genymotion?
Yes, it's different from the Android SDK emulator (10.0.2.2), and these are forward to localhost of host machine.
Hmm... I wonder if there's a way to detect the runtime environment then in Android? Maybe auto set this up?
The part of the brain that's responsible for logic & self-preservation is yelling: NO! BAD IDEA! DON'T DO IT!
I'm going to dig a bit.