What's the recommended way to use environment variables in a SvelteKit project?

Hello, I'm new to workers and want to know how I can manage and access environment variables in a SvelteKit project with Vite, the docs are really vague and confusing on how and the SvelteKit docs mention using getPlatformProxy but I'm not sure if it's for local development only or also prod, How am I supposed to use them?
2 Replies
Fizzgig
Fizzgig3w ago
If by env variables you mean api and auth keys, you will need to import them using env/static Then you'll need to go to your worker and add the variables as secrets
Fizzgig
Fizzgig3w ago
No description

Did you find this page helpful?