Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Could not resolve all files for configuration ':app:debugCompileClasspath' in react native

I tried running react-native run-android after having set up React Native using react-native init as I hate expo. But, I am getting problem here as this:

Could not resolve all files for configuration ':app:debugCompileClasspath'.
> Could not find support-vector-drawable.aar (com.android.support:support-vector-drawable:27.1.1).
  Searched in the following locations:
      https://jcenter.bintray.com/com/android/support/support-vector-drawable/27.1.1/support-vector-drawable-27.1.1.aar
> Could not find livedata-core.aar (android.arch.lifecycle:livedata-core:1.1.0).
  Searched in the following locations:
      https://jcenter.bintray.com/android/arch/lifecycle/livedata-core/1.1.0/livedata-core-1.1.0.aar
> Could not find viewmodel.aar (android.arch.lifecycle:viewmodel:1.1.0).
  Searched in the following locations:
      https://jcenter.bintray.com/android/arch/lifecycle/viewmodel/1.1.0/viewmodel-1.1.0.aar
> Could not find runtime.aar (android.arch.core:runtime:1.1.0).
  Searched in the following locations:
      https://jcenter.bintray.com/android/arch/core/runtime/1.1.0/runtime-1.1.0.aar

Any idea on how to get this working? I tried every question possible, but none of them seems working!

like image 840
JustABeginner Avatar asked Aug 08 '26 21:08

JustABeginner


1 Answers

This worked! Just move google() from bottom to top in allprojects > repositories in build.gradle of module. Reference -> https://stackoverflow.com/a/52950717/8237551

like image 82
JustABeginner Avatar answered Aug 10 '26 09:08

JustABeginner