I want to use Google places API but I can't sync the project with "com.google.android.libraries.places:1.0.0:"
dependency. How to add the places in my project?.
The library in documentation is wrong I guess, use this, it works. I had same issue few days back , gave a feedback to them on documentation they still didn't fix it.
implementation 'com.google.android.libraries.places:places:2.1.0'
You can see how to add places autocomplete over here
Edit: Seems like they finally fixed the documentation
maven { url "https://maven.google.com" }
in project level build.gradle
below jcentre() –
Material Places.initialize(getApplicationContext(), "GOOGLE_API_KEY")
–
Material try to change
compileOnly "com.facebook.react:react-native:+"
by
api "com.facebook.react:react-native:+"
I also stuck with the same issue, now i removed this issue. According to google, "The v1.0.0 release of the Places SDK for Android introduces an all-new static library with updated functionality. The Google Play Services version of the Places SDK for Android (in Google Play Services 16.0.0) is deprecated as of January 29, 2019, and will be turned off on July 29, 2019."
Add following dependency it will work...
implementation 'com.google.android.libraries.places:places:1.0.0'
For more information you can visit, https://developers.google.com/places/android-sdk/client-migration
© 2022 - 2024 — McMap. All rights reserved.
build.gradle
– Cavalry