---
version: 0.2.0
releasedAt: 2026-06-21
slug: v0-2-0
title: Typed env + faster boot
summary: Declare your environment once; it's validated at startup with a hard public/secret boundary.
tags: [feature, performance]
---

## Typed environment

`defineEnv` validates every variable at boot (fail-fast, all problems
listed) and hands back typed, coerced accessors instead of
`string | undefined`:

```ts
export const env = defineEnv({
  MAX_BATCH:  envVar.number({ access: 'public', default: '50' }),
  STRIPE_KEY: envVar.string({ access: 'secret' }),   // never reaches the browser
})
```

A `secret` is unrepresentable in the browser bundle — enforced by the
compiler and the bundler, not by discipline.

## Faster cold boot

Roughly **30% faster** startup on a warm schema cache.
