type First<T> = T extends any[] ? T[0] : never;
const myarr = [1, 2, 3]
type FirstItem = First<myarr>; // This errors saying you should pass type instead of value
type FirstItem1 = First<[1, 2, 3]> // This works even if we are passing value
type First<T> = T extends any[] ? T[0] : never;
const myarr = [1, 2, 3]
type FirstItem = First<myarr>; // This errors saying you should pass type instead of value
type FirstItem1 = First<[1, 2, 3]> // This works even if we are passing value