Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Parse, Don’t Validate. Parent comment
type NonEmptyArray<T> = [T, ...T[]];
That is: A type of "NonEmptyArray" of T is an array of one element of type T, followed by any number of type-T elements.
There are no comments on this comment yet.
type NonEmptyArray<T> = [T, ...T[]];
That is: A type of "NonEmptyArray" of T is an array of one element of type T, followed by any number of type-T elements.