Creates a new readonly tuple type where the element at index I in T is replaced with type V.
I
T
V
The readonly tuple type.
The index to update (must be a valid index literal for T).
The new type for the element at index I.
A new readonly tuple type with the element at index I updated.
type SA1 = Tuple.SetAt<[1, 2, 3], 1, 'x'>; // readonly [1, 'x', 3]// type SA2 = Tuple.SetAt<[1, 2], 2, 'x'>; // Error: Index '2' is out of bounds. Copy
type SA1 = Tuple.SetAt<[1, 2, 3], 1, 'x'>; // readonly [1, 'x', 3]// type SA2 = Tuple.SetAt<[1, 2], 2, 'x'>; // Error: Index '2' is out of bounds.
Creates a new readonly tuple type where the element at index
IinTis replaced with typeV.