Function: isSome()
isSome<
O>(option):option is Extract<O, { type: "Some" }>
Type guard to check if an Option is a Some.
Type Parameters
O
O extends Option<unknown>
The Option type to check.
Parameters
option
O
The Option to check.
Returns
option is Extract<O, { type: "Some" }>
true if the option is a Some, otherwise false.