Union Type
↔ Compound Type join by |
Type Operator to define each member of Type set can EITHER be
aka Type-Union, Union
Discriminated Union
Union Type with overlapping property of different values
References
- [
!snippet [
Intersection Type](intersection-type) of 2 [**_
Union Type`_**](union-type)
type DateTime = Date | string
type Label = string | number
type Combined = DateTime & Label
typeof Combined`](snippet-intersection-type-of-2-union-type-typeof-combined) ↔ string
Discriminated Union
↔ Union Type with overlapping property of different valuesDiscriminant
↔ Common Type in Union Type with different values