You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Nxut3. Dont work originEnvKey when ssr: false in nuxt.config. Because originEnvKey used just at getServerOrigin function, which in node_modules/@sidebase/nuxt-auth/dist/runtime/server/services/utils.js. There used useRuntimeConfig(). But we dont have access to config[normalized], because in client at config not private variables from .env.
My solution is possible. Add a condition "envVariableName.startsWith(NUXT_PUBLIC_)"
Additional context
No response
Logs
The text was updated successfully, but these errors were encountered:
Solution with baseURL: process.env.NUXT_PUBLIC_API_BASE_URL+ "/api/auth", not for me. Because I provide env vars in runtime (in start app). At build I don`t have them
Environment
I use:
runtimeConfig: { public: { apiBaseUrl: process.env.NUXT_PUBLIC_API_BASE_URL, }, { auth: { originEnvKey: 'NUXT_PUBLIC_API_BASE_URL', provider: { type: 'local', // another configs } } } }
Reproduction
runtimeConfig: { public: { apiBaseUrl: process.env.NUXT_PUBLIC_API_BASE_URL, }, { auth: { originEnvKey: 'NUXT_PUBLIC_API_BASE_URL', provider: { type: 'local', // another configs } } } }
Describe the bug
Nxut3. Don
t work originEnvKey when ssr: false in nuxt.config. Because originEnvKey used just at getServerOrigin function, which in node_modules/@sidebase/nuxt-auth/dist/runtime/server/services/utils.js. There used useRuntimeConfig(). But we don
t have access to config[normalized], because in client at config not private variables from .env.My solution is possible. Add a condition "envVariableName.startsWith(NUXT_PUBLIC_)"
Additional context
No response
Logs
The text was updated successfully, but these errors were encountered: