Convert a tuple or readonly array type to a union.
Tuple or readonly array type
Extracts the element types of a tuple or array and produces a union of those element types.
type Tup = [ string, number, boolean ];type U = TupleToUnion< Tup >;// string | number | boolean Copy
type Tup = [ string, number, boolean ];type U = TupleToUnion< Tup >;// string | number | boolean
Convert a tuple or readonly array type to a union.