Failed to resolve: com.google.android.libraries.places:1.0.0:

左心房为你撑大大i 提交于 2020-02-23 11:28:26

问题


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?.


回答1:


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




回答2:


try to change

compileOnly "com.facebook.react:react-native:+"

by

api "com.facebook.react:react-native:+"



回答3:


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



来源:https://stackoverflow.com/questions/54878944/failed-to-resolve-com-google-android-libraries-places1-0-0

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!