40. implement UnionToIntersection<T>
Share
- accepted / - tried
Implement UnionToIntersection<T>
to get an Intersection type from Union type.
type A = UnionToIntersection<{a: string} | {b: string} | {c: string}> // {a: string} & {b: string} & {c: string}