DEV Community

Discussion on: Using environment variables in SvelteKit (and Vite)

tonyketcham profile image
Tony Ketcham

Thank you! This helped me figure out the issue I was having when trying to import .env vars into my endpoints.

The SvelteKit project init had set the ecma version in my eslint parserOptions to 2019. Changing that to 2020 and defining the compilerOptions in my jsconfig.json fixed the issue.

danawoodman profile image
Dana Woodman Author

Glad I could help!