TRAITS

schema-decoding-defaults-for-configuration

For schema-decoded configuration, express optional-field defaults with Effect Schema decoding defaults rather than fallback expressions at consumption sites. Decode imported configuration with S.decodeUnknownEffect, and expose the schema’s Encoded type for caller-authored configuration so defaulted fields remain optional.

When
defining, decoding, or consuming schema-backed configuration with optional defaults.
  • text/typescript
  • text/tsx
c3a45d95 · Source (opens in a new tab)

Skipping this trait

Add this comment before any code to skip the trait for a whole file. A reason is required.

File header
// traits-ignore-file c3a45d95-ade4-452c-8f2c-f4d567624d36: <reason>