@utilities-studio/vite-env
v1.0.5
Published
Generate vite-env.d.ts type declarations from VITE_ environment variables
Readme
@utilities-studio/vite-env
Generate vite-env.d.ts type declarations from VITE_ environment variables.
Scans process.env for all VITE_ prefixed variables and generates a strict ImportMetaEnv interface.
Usage
# Run with env file loaded
bun --env-file=.env.development bunx @utilities-studio/vite-envOutput
Creates src/vite-env.d.ts with typed ImportMetaEnv:
interface ImportMetaEnv {
readonly VITE_SUPABASE_URL: string
readonly VITE_SITE_URL: string
}Requirements
- Bun runtime
.env.developmentfile in project root
