Kit
Functions

none

none<T>(): Option<T>

Creates a new Option that contains no value.

This function explicitly represents an absent value.

Type Parameters

Type ParameterDescription
TThe type of the expected absent value.

Returns

Option<T>

An Option containing no value.

Example

Creating an empty Option.

const empty = none<number>();
isOption(empty); // true
isSome(empty);   // false
isNone(empty);   // true

See

On this page