MCPcopy Create free account
hub / github.com/effect-app/libs / withDecodingDefault

Function withDecodingDefault

repos/effect/packages/effect/src/Schema.ts:5819–5830  ·  view source on GitHub ↗
(
  defaultValue: Effect.Effect<S["Encoded"], SchemaError, R>,
  options?: DecodingDefaultOptions
)

Source from the content-addressed store, hash-verified

5817
5818/**
5819 * Options for {@link withDecodingDefaultKey} and {@link withDecodingDefault}.
5820 *
5821 * **Details**
5822 *
5823 * - `encodingStrategy`:
5824 * - `"passthrough"` (default): pass the value through during encoding
5825 * - `"omit"`: omit the key from the encoded output
5826 *
5827 * @category options
5828 * @since 4.0.0
5829 */
5830export type DecodingDefaultOptions = {
5831 readonly encodingStrategy?: "omit" | "passthrough" | undefined
5832}
5833

Callers 1

withDecodingDefaultTypeFunction · 0.70

Calls 5

toEncodedInterface · 0.85
optionalInterface · 0.70
decodeToFunction · 0.70
omitMethod · 0.65
pipeMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…