Google Maps and Google Places Autocomplete API with Rails, Turbolinks, and Stimulus.js Discussion
Thanks Chris, great video.
I have tried to work with Google Maps Places API in the past, but I have faced an issue with their API Policies. According to their policy you cannot save details like the place address which was autocompleted in your application database (https://developers.google.com/places/web-service/policies#pre-fetching,-caching,-or-storage-of-content). Also I remember you can save the latitude and the longitude in the database but you have to refresh it every 30 days (https://cloud.google.com/maps-platform/terms/maps-service-terms).
What are your thoughts on this?
It sounds like they more or less don't want you downloading all their data and creating your own copy. That's their way of enforcing it. There are several good alternatives that might have better licensing.
So does that mean that you are good if the app runs a place update each month? If so, for smaller apps, you are golden. The Mapbox API might be a good alternative.
Overall, thanks Chris for offering this look into how to use Google's API with rails. I haven't seen anyone put something like this together in a while.
Me too. I prefer Stimulus over all other options. Is the Rails way. So easy and useful.