Home > @wixc3/common > last
Picks the last element of an iterable
Signature:
export declare function last<T>(iterable: Nullable<Iterable<T>>): T | undefined;
Parameter | Type | Description |
---|---|---|
iterable | [Nullable](/core3-utils/common.nullable.html)<Iterable<T>> |
Returns:
T | undefined
undefined for null/empty iterable