I am trying to build a react-native app on my mobile phone.
I do have environment path set in my environment variable
I have my phone in debugging mode with adb devices showing phone connected.
My java path is C:\Program Files\Java\jdk-10.0.2
I get the below error on react-native run-android
ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation.
Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/getting-started.html