None
Hierarchy
- Option<never>
- None
Index
Properties
publicstaticreadonlyinstance
The singleton instance of None
.
Prefer using Option.none
instead.
Accessors
publicstaticnone
Returns a
None
value.Returns Option<never>
Methods
publicstaticall
Returns the array of
Some
values, if all areSome
.Type parameters
- T: readonly Option<unknown>[]
Parameters
values: T
Returns Option<{ -readonly [ K in string | number | symbol ]: OptionType<T[K<K>]> }>
publicstaticany
Returns the first
Some
value in the array, if any isSome
.Type parameters
- T: readonly Option<unknown>[]
Parameters
values: T
Returns Option<OptionType<T[number]>>
publicstaticassert
publicstaticis
publicstaticsome
Returns a
Some
value.Type parameters
- T
Parameters
value: T
Returns Option<T>
publicstaticunwrap
Unwraps the option, yielding the content of a
Some
.Type parameters
- T
Parameters
option: Option<T>
Returns T
Represents an optional value. An
Option
is either aSome
value containing a value, or aNone
value containing no value.