Skip to main content
Module

x/rambda/immutable.d.ts>last

Faster and smaller alternative to Ramda
Go to Latest
function last
import { last } from "https://deno.land/x/rambda@v8.3.0/immutable.d.ts";

It returns the last element of input, as the input can be either a string or an array.

Parameters

input: string

Returns

string

Parameters

emptyList: readonly []

Returns

undefined

Type Parameters

T extends readonly unknown[]

Returns

LastArrayElement<T>