readonly array in typescript

Solutions on MaxInterview for readonly array in typescript by the best coders in the world

showing results for - "readonly array in typescript"
Andres
10 Aug 2017
1function foo(pair: readonly [string, string]) {
2    console.log(pair[0]);   // okay
3    pair[1] = "hello!";     // error
4}
5