Get the item at the given index, or undefined if the sequence is empty. Negative values count backwards from the end.
undefined
import { pipe } from "yta";import { at, of } from "yta/sync";pipe(of("foo", "bar", "baz", "quux"), at(2));// => "baz"pipe(of("foo", "bar", "baz", "quux"), at(-1));// => "quux" Copy
import { pipe } from "yta";import { at, of } from "yta/sync";pipe(of("foo", "bar", "baz", "quux"), at(2));// => "baz"pipe(of("foo", "bar", "baz", "quux"), at(-1));// => "quux"
See also:
Get the item at the given index, or
undefinedif the sequence is empty. Negative values count backwards from the end.See also: