DEV Community

Discussion on: ✨ Introducing use-places-autocomplete: React hook for Google Maps Places Autocomplete

Collapse
 
glacian22 profile image
Abram Thau

Hi Welly, this is really nicely designed! One concern though, you're using a script tag to bring in the google maps api, but that exposes the API key to the user. Any ideas on how to keep the key safe?

Collapse
 
wellyshen profile image
Welly

Google has provided many way to limit the usage of the API key. You can configure it via Google Cloud Console (console.cloud.google.com)