Skip to content

parseEnvValueAsBool

parseEnvValueAsBool(value): boolean | null

Defined in: env/parse-env-value.ts:30

Read an environment variable value as a boolean.

Recognises every flavor printEnvBoolValue writes, case-insensitively.

string | null | undefined

The value to read.

boolean | null

The boolean it spells, or null if it spells none.