Type alias Head<Input>

Head<Input>: HeadAndTail<Input>[0]

Initial value of an array or string.

Example

const array = ["🟢", "🟩", "💚"];
const head: Head<typeof array> = "🟢";

Type Parameters

  • Input extends ArrayLike<unknown>