N
Nuxt2mo ago
Joaquín

why nuxt not exposing `NUXT_` nor `NUXT_PUBLIC_` env entries in `import.meta.env`?

When configuring custom entries via vite.define or runtimeConfig.publicthere is no way to access them via import.meta.env. The only way is using .env file + VITE_ prefix: I need some entries in a service worker (firebase stuff for example) https://github.com/vite-pwa/vite-plugin-pwa/discussions/762#discussioncomment-10843259
1 Reply
Joaquín
JoaquínOP2mo ago
I cannot use useRuntimeConfig().public inside the service worker I need those entries in dev server and build time
Want results from more Discord servers?
Add your server