I am trying to develop my first react-native Android
app. When I run
sudo react-native run-android
I get the following error
What I did was to change the target my application was compiled against. To do this edit the file android/app/build.gradle
on your project and modify the following:
compileSdkVersion 24
buildToolsVersion "24.0.2"
This should match whatever you have installed without requiring to download another API version.
I followed the React Native Getting Started instructions and my ANDROID_HOME and PATH was right but I was still getting this error.
The solution was to install "Android 6.0 (Marshmallow)" from this screen (without clicking "Show Package Details"):