Returns the element at the specified position in the source array.
It produces the same wide type as the "at" method of the source array.
at
at(0)([1, 2, 3]); // 1 with type numberat(1)([1, 2, 3] as const); // 2 with literal type 2at(-1)([1, 2, 3] as const); // 3 with literal type 3 Copy
at(0)([1, 2, 3]); // 1 with type numberat(1)([1, 2, 3] as const); // 2 with literal type 2at(-1)([1, 2, 3] as const); // 3 with literal type 3
Returns the element at the specified position in the source array.
It produces the same wide type as the "at" method of the source array.
See
at
Example