tushar10sh / sveltekit-oidc

Sveltekit + OpenID Auth (confidential flow with Keycloak) + SSR Auth
MIT License
45 stars 9 forks source link

envrionment variable undefined #2

Open Snukii opened 2 years ago

Snukii commented 2 years ago

I'm running into an issue trying to use this package;

_keyclock/utils.js can't seem to load the envrionment variables: Uncaught (in promise) TypeError: can't access property "VITE_OIDC_ISSUER", import_meta.env is undefined in firefox and Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'VITE_OIDC_ISSUER') in chrome at utils.js line 2.

Environment variables work just fine elsewhere, I used VITE_OIDC_ISSUER in keycloak.svelte no problem.

SarcevicAntonio commented 2 years ago

I got the same issue and #3 is the same ✌️

tushar10sh commented 2 years ago

@Snukii and @SarcevicAntonio Sorry you have to run into such an issue. Which version of sveltekit-oidc are you using? Also, I am using node version 14.17.1.