tuple type
A fixed-length list where each position has its own meaning and type, such as [major, minor, patch].
In more detail
In TypeScript, type Ver = [number, number, number] declares a tuple of exactly three numbers. The governance lesson stores versions this way.
Related terms
- union type — A type that allows one of several listed types or values, written with a vertical bar, such as int | None in Python or "small" | "large" in TypeScript.
- semantic versioning — A version numbering scheme of three numbers, major.minor.patch, raised for breaking changes, new features and fixes respectively.
- TypeScript — JavaScript with added type annotations, checked by a compiler before the code runs.
Taught in
- System Governance: Changesets, Semantic Versioning & Deprecation — Design Systems & Component Engineering