af/envalid
Environment variable validation for Node, Bun, and other compatible JS runtimes observed · 2026-08-28
Health v2 · maintenance only
83/100
- Activity 98
- Release rhythm 55
- Longevity 100
How is this computed?
round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10) — computed 2026-09-03. Adoption (stars, forks) is never an input.
- gap_med: 332
- age_days: 5025
- days_rel: 85
- days_push: 12
- n_releases_24m: 2
Adoption not part of the score
1588 stars · 68 forks observed · 2026-08-28
What it is AI-extracted, prompt v1, taxonomy v1, 2026-08-30, confidence not recorded
Envalid is a small TypeScript library for validating and accessing environment variables in Node.js, Bun, and other compatible JavaScript runtimes. It ensures programs only run when required environment variables are present and valid, providing a type-safe, immutable API for env access.
Use cases
- validate environment variables in a node app
- fail fast when required env vars are missing
- parse env vars into typed values like booleans and numbers
- enforce allowed choices for NODE_ENV
- load and validate .env config with dotenv
- get type-safe access to process.env in TypeScript
When to choose
- you want zero-dependency, type-safe env validation for Node or Bun
- you need executable documentation of your app's environment requirements
- you want immutable, sanitized env objects with custom validators and reporters
When to avoid
- you need full config management beyond environment variables
- you're not on a JavaScript runtime
- you only need simple dotenv loading without validation
Facets
library · maturity stable
form-handling configuration-management developer-tools developer-tools backend bun cross-platform environment-variables env-validation typescript dotenv zero-dependency nodejs
2 sources
- readme: https://github.com/af/envalid · fetched 2026-08-28 · ca431a72ef3b
- registry_npm: https://registry.npmjs.org/envalid · fetched 2026-08-29 · ab212b359312
Member repositories
| Repository | Role | Health v2 |
|---|---|---|
| af/envalid | main | 83 |
For agents
Data as of 2026-08-30T08:39:29.467469+00:00 · Report a problem