0

I'm trying to add Lottie library into my Android Project using this line :

implementation 'com.airbnb.android:lottie:2.5.0'

& after syncing it shows this errors :

Unable to resolve dependency for ':app@debug/compileClasspath': Could not resolve com.airbnb.android:lottie:2.5.0.

Unable to resolve dependency for ':app@debugAndroidTest/compileClasspath': Could not resolve com.airbnb.android:lottie:2.5.0.

Unable to resolve dependency for ':app@debugUnitTest/compileClasspath': Could not resolve com.airbnb.android:lottie:2.5.0.

Unable to resolve dependency for ':app@release/compileClasspath': Could not resolve com.airbnb.android:lottie:2.5.0.

I've tried adding other Lottie versions as well but still showing the same errors. I'm using Android Studio 3.2 & Target SDK is 28. Please help me how to solve this issue.

stkent
  • 19,772
  • 14
  • 85
  • 111

3 Answers3

0

Plain 2.5 version doesn't seem to exist (as per their Github repo)

Use 2.7 instead :

implementation 'com.airbnb.android:lottie:2.7.0'
Arthur Attout
  • 2,701
  • 2
  • 26
  • 49
0

This (could not resolve error) only occurs when you are missing files or components related to specific implementation dependency Make sure to add json file as well in the res folder... app-->res then right click and new--->folder-->assets folder and paste it..

0

Use 3.0.0 and you will be good to go. Happy coding

dependencies {
  implementation 'com.airbnb.android:lottie:3.0.0'
}
Marie
  • 1
  • 3