Breaks an iterable into array chunks
Return concatenation of iterators.
Drops elements that do not meet the predicate f
.
Streaming result: works with endless iterables.
Returns true if items in two iterables are equal, as
determined by the equality
function.
Order matters. It compares items at the same 'step' of each iterable.
Returns true if f
returns true for
every item in iterable.
Yields v
for each item within it
.
Filters an iterable, only yielding items which match f
.
Returns first item from iterable it
that matches predicate f
Returns a 'flattened' copy of array, un-nesting arrays one level. Streaming: works with unlimited iterables.
Execute function f
for each item in iterable.
If f
returns false, iteration stops.
Yield values from array
, one at a time.
Use interval
to add time between each item.
The first item is yielded without delay.
Access callback
as an iterable:
Access awaited callback
as an iterable:
Yield values from iterable
, one at a time.
Use interval
to add time between each item.
The first item is yielded without delay.
Returns true if all values in iterables are equal, regardless of their position. Uses === equality semantics by default.
Retrieve values from an iterator, passing them to a callback. Allows iterator to be started, paused, or restarted and an optional delay between reading items from iterator.
Returns the last item of an iterable, or undefined if it yields no results.
Maps an iterable through function f
Returns the maximum value of an iterable as it changes. Streaming result: works with endless iterables.
Returns the 'max' of some iterable using the provided scoring function. It only yields a value when iterator finishes.
Returns a stream of minimum values.
Returns the 'min' of some iterable using the provided scoring function. It only yields a value when iterator finishes.
Returns the min, max, avg and total of the array or iterable. Any values that are invalid are silently skipped over.
Reduce for iterables
Returns a section from an iterable.
Returns true the first time f
returns true. Useful for spotting any occurrence of
data, and exiting quickly
Returns an array of values from an iterator.
Returns unique items from an iterable or array of iterables.
Filters the input
iterable, only yielding unique values. Use unique to compare
by object reference instead.
Loops over a generator until it finishes, calling callback
.
Useful if you don't care about the value generator produces, just the number of loops.
Combine same-positioned items from several iterables
Calls
callback
whenever the generator produces a value.