Skip to main content

SettledOption

@ts-rust/std


@ts-rust/std / Option / SettledOption

Type Alias: SettledOption<T>

type SettledOption<T> = Option<Awaited<T>>;

Defined in: packages/std/src/option/interface.ts:39

A synchronous Option where the contained value T is guaranteed to be non-PromiseLike, ensuring immediate availability without awaiting.

This restricted Option variant enforces synchronous values for methods like insert, getOrInsert, and getOrInsertWith, which mutate the option. Use it when you need a type-safe, synchronous option.

Type Parameters

Type Parameter

T