Defined

Defined<Type>

A generic type Defined indicates the generic type variable Type is never undefined. It takes generic type variable Type constrained by undefined which constraint causes its change to never.

defined.type.ts
type Defined<Type> = Type extends undefined ? never : Type;

Generic type variables

Type

A generic type variable Type is never undefined but captured type.

Last updated