Converts a union of types into an intersection of those same types.
type Union = { size: string } | { color: string };type Intersection = UnionToIntersection<Union>;// => { size: string } & { color: string } Copy
type Union = { size: string } | { color: string };type Intersection = UnionToIntersection<Union>;// => { size: string } & { color: string }
Converts a union of types into an intersection of those same types.