Get the difference of two union types.
First union type
Second union type
Produces a union of types that are in A but not in B.
A
B
type A = 'a' | 'b' | 'c';type B = 'a' | 'x';type C = UnionDifference< A, B >; // 'b' | 'c' Copy
type A = 'a' | 'b' | 'c';type B = 'a' | 'x';type C = UnionDifference< A, B >; // 'b' | 'c'
Get the difference of two union types.