When I make the command "react-native run-android" then it happened:
FAILURE: Build failed with an exception.
- What went wrong:
A problem occurred configuring root project 'AsomeProject'.Could not resolve all files for configuration ':classpath'.
Could not find com.android.tools.build:gradle:3.0.1.
Searched in the following locations:
https://jcenter.bintray.com/com/android/tools/build/gradle/3.0.1/gradle -3.0.1.pom
https://jcenter.bintray.com/com/android/tools/build/gradle/3.0.1/gradle -3.0.1.jar
screenshot:
Best Answer
I had the same problem, I tried Manoj Prabhakar's solution but I fixed adding the
google()
repository to the buildscript block in the project levelbuild.gradle