The documentation shows (#ReadOnlyArray) how to do it using an interface, but as I am exploring the language I wondered why does this not work as well ?
type TraverseTuple<T extends Array<unknown>> = {
readonly [P in keyof T]: T[P];
}
const test: TraverseTuple<[string, number, string, number]> = ['s', 1, 'o', 2];
test[1] = 0; // not readonly !