server\api access
hi all, I'm a bit new to nuxt and I'm struggling to figure out where the server side code ends and the client side code begins. I want to access some google APIs and naturally I do not want to expose these keys to the client.
Will accessing these APIs here be insecure? Sorry if this is a noob question.
2 Replies
It'll be secure as long as you remember to put the API keys in the right place. See https://nuxt.com/docs/api/composables/use-runtime-config#define-runtime-config
Nuxt
useRuntimeConfig · Nuxt Composables
Access runtime config variables with the useRuntimeConfig composable.
Thanks!!