A TypeScript identity type — type aliases that return the input type unchanged.
| Type | Description |
|---|---|
Identity<T> |
Returns the type unchanged |
Relation<T> |
Already common in TypeORM |
Self<T> |
Emphasizes that the type refers to itself |
Same<T> |
Clear that the output equals the input |
AsIs<T> |
Take the type as it is |
Unchanged<T> |
Explicitly says no transformation |
Lazy<T> |
Indicates a lazily evaluated type |
Forward<T> |
Used for forwarding generic parameters |
Ref<T> |
Reference wrapper for types |
Alias<T> |
Alternative name for a type |
Placeholder<T> |
Placeholder for a type parameter |
K<T> |
From combinatory logic (K is constant) |
I<T> |
Short for identity, returns the type unchanged |
MIT License (c) 2026