TIL: How to type an array in Typescript to express this array has at least 1 element
By default when typing an array in Typescript I would do the following:
const myArray: T[] = ... // operation that returns an array of type T
However when I'm certain this array has at least one element or when I want to type a function parameter th...