News for hackers. Stuff that matters.
Re:TypeScript 3.7 by jakelazaroff on Tuesday November 05, 2019 @05:43PM (#21457559)
For array types, I don't think there's a way. You can type x as a tuple like this:

    const x: [number, number] = [1, 2];
In which case you'll only be able to access indices zero and one.

There are no comments on this comment yet.