Skip to content

Latest commit

 

History

History

package

Folders and files

README.md

env

Only declared variables, checked at boot.

Contract-first environment configuration with typed schemas. Define your env once with Standard Schema (Zod, Valibot, ArkType…), get a fully typed env object that merges per-environment config with your environment variables.

Runtime-agnostic core — Node, Bun, Deno, browser, Workers, Edge. Opt-in entry points: a filesystem-based config loader (works on Node, Bun, and Deno), a Vite plugin, a React <EnvScript /> helper for hydrating runtime env across SSR or CSR, and a curated set of Zod-based schema primitives.

Installation

pnpm add @variablelab/env

@variablelab/env is agnostic to the schema validator. If you'll use Zod (the docs default, and the validator behind the optional @variablelab/env/zod primitives), install it alongside:

pnpm add zod

Documentation

lab.variable.land/env/docs

Examples

Runnable apps under examples/:

License

MIT