Open biesbjerg opened 4 months ago
What do you think of https://github.com/Julien-R44/vite-plugin-validate-env/pull/26 ?
It loads all environment variables, enabling validation, but only exposes variables (through define) if their keys begin with the configured envPrefix.
I'd like to validate env vars coming from
.env
as well as from the system.System environment:
.env
:vite.config.ts
:Above won't work because we're only able to validate vars prefixed with
envPrefix
(VITE_APP_
), henceSENTRY_AUTH_TOKEN
will always report as missing.Do you think there's a way to achieve this? Would you accept a PR, and if so, any pointers how you'd like it done?