Skip to content

OmitNever

Category
Basic Operation

Get Union type of object property types, but filtered out never types.

Usage

ts
import type { 
OmitNever
} from '@utype/core'
type
Props
= {
name
: string;
age
: never;
visible
: boolean;
} // Expect: string | boolean type
OmitNeverProps
=
OmitNever
<
Props
>