smeijer / leaflet-geosearch

A geocoding/address-lookup library supporting various api providers.
https://smeijer.github.io/leaflet-geosearch/
MIT License
1.04k stars 273 forks source link

Use Places API for GoogleProvider? #170

Open johan-- opened 6 years ago

johan-- commented 6 years ago

The GoogleProvider is not returning any results in our application (with a proper Google API key), nor is the demo application working when Google is selected.

Update: we are seeing 403s in the Google Cloud Platform, awaiting a response from their support.

Which API should be used: GeoCoding or Places? The latter is used for auto-completion, yet it seems as if the GoogleProvider is using the geoCoding API (since that is where the 403s are).

screenshot-console cloud google com-2018 07 16-13-11-28

smeijer commented 4 years ago

The google provider is indeed using the GeoCoding api. Would it be better to use Places? Or do we need a hybrid approach? Places for the suggestions, and the GeoCoding for the selection?

minzdrav commented 1 year ago

Hello leafleat-geoserach team Could you please implement places api for google provider? As parameter or as separate provider - both options are good. Places api is better for search, because it can find more locations. Places and geocoding differences: https://cloud.google.com/blog/products/maps-platform/address-geocoding-in-google-maps-apis

itaymining commented 11 months ago

Hello leafleat-geoserach team Could you please implement places api for google provider? As parameter or as separate provider - both options are good. Places api is better for search, because it can find more locations. Places and geocoding differences: https://cloud.google.com/blog/products/maps-platform/address-geocoding-in-google-maps-apis

you are right. @smeijer please use google "places" autocomplete for autocomplete then grab place_id and get the data from google "geocoder" api

smeijer commented 11 months ago

I'd be happy to merge a pull request adding such a provider.