API reference@evolu/common › Config

Strict configuration Types with explicit application policy.

Decode configuration at startup, then pass validated values to constructors or Tasks. The application decides how to load configuration, combine sources, and apply defaults. Declare defaults with withDefault, or use ?? where a value is consumed. Invalid supplied values still fail decoding.

Resolve source precedence before replacing absence with defaults. If a source Type already provides defaults and later composition needs to distinguish them from supplied values, use strategy: "preserve" and inspect defaultUsed explicitly. Preserving this evidence does not choose a merging policy: the application still decides which source wins.

env creates a pure, reversible codec. It does not read global state, load files, merge sources, or introduce a Run dependency. Tests can pass ordinary objects; a Node.js entry point can pass process.env.

Functions

FunctionDescription
envCreates a reversible environment-variable codec with a flat decoded output.

Interfaces

InterfaceDescription
EnvTypeThe configuration codec returned by env.

Type Aliases

Type AliasDescription
EnvNameAn environment variable name in Evolu's configuration convention.
EnvPropsFields and one-level namespace groups used to construct an env Type.

Variables

VariableDescription
EnvNameAn environment variable name in Evolu's configuration convention.