core3-utils

@wixc3/common on Github

Home > @wixc3/common > next

next() function

Find the element following an item

Signature:

export declare function next<T>(iterable: Nullable<Iterable<T>>, item: T): T | undefined;

Parameters

Parameter Type Description
iterable [Nullable](/core3-utils/common.nullable.html)<Iterable<T>>
item T

Returns:

T | undefined

undefined if item is last or not found