OptionUnify<A>Type-level unification support for Option values.
When to use
Use when extending Effect's type-level unification support for Option.
Details
This is used by Effect's Unify machinery to preserve the contained value
type when generic code returns or combines Option values. Users normally
do not need to reference this interface directly.
export interface interface OptionUnify<A extends { [Unify.typeSymbol]?: any; }>Type-level unification support for Option values.
When to use
Use when extending Effect's type-level unification support for Option.
Details
This is used by Effect's Unify machinery to preserve the contained value
type when generic code returns or combines Option values. Users normally
do not need to reference this interface directly.
OptionUnify<function (type parameter) A in OptionUnify<A extends { [Unify.typeSymbol]?: any; }>A extends { [import UnifyUnify.const typeSymbol: typeof Unify.typeSymbolDefines the unique symbol used to identify the type information for unification.
When to use
Use when you need a type-level protocol key that exposes the source type
read by Unify from a protocol-enabled data type.
Details
This symbol is a type-level protocol key. It stores the source type that
unification reads when widening protocol-enabled values.
The type of the typeSymbol.
When to use
Use to reference the type information property key in type-level protocol
definitions.
Details
This type represents the unique symbol used for storing type information
in types that support unification. It's used in type-level operations
to access and manipulate type information.
typeSymbol]?: any }> {
OptionUnify<A extends { [Unify.typeSymbol]?: any; }>.Option?: () => A[Unify.typeSymbol] extends Option<infer A0> | infer _ ? Option<A0> : neverOption?: () => function (type parameter) A in OptionUnify<A extends { [Unify.typeSymbol]?: any; }>A[import UnifyUnify.type typeSymbol = typeof Unify.typeSymbolDefines the unique symbol used to identify the type information for unification.
When to use
Use when you need a type-level protocol key that exposes the source type
read by Unify from a protocol-enabled data type.
Details
This symbol is a type-level protocol key. It stores the source type that
unification reads when widening protocol-enabled values.
The type of the typeSymbol.
When to use
Use to reference the type information property key in type-level protocol
definitions.
Details
This type represents the unique symbol used for storing type information
in types that support unification. It's used in type-level operations
to access and manipulate type information.
typeSymbol] extends type Option<A> = None<A> | Some<A>The Option data type represents optional values. An Option<A> is either
Some<A>, containing a value of type A, or None, representing absence.
When to use
Use to represent initial values that may not yet exist
- Returning from partial functions (not defined for all inputs)
- Managing optional fields in data structures
Namespace containing utility types for Option.
When to use
Use to access type-level helpers associated with Option.
Option<infer function (type parameter) A0A0> | infer function (type parameter) __ ? type Option<A> = None<A> | Some<A>The Option data type represents optional values. An Option<A> is either
Some<A>, containing a value of type A, or None, representing absence.
When to use
Use to represent initial values that may not yet exist
- Returning from partial functions (not defined for all inputs)
- Managing optional fields in data structures
Namespace containing utility types for Option.
When to use
Use to access type-level helpers associated with Option.
Option<function (type parameter) A0A0> : never
}