Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/itertools/mod.ts>chain

🦕 A TypeScript port of Python's itertools and more-itertools for Deno
Latest
function chain
import { chain } from "https://deno.land/x/itertools@v1.1.2/mod.ts";

Returns an iterator that returns elements from the first iterable until it is exhausted, then proceeds to the next iterable, until all of the iterables are exhausted. Used for treating consecutive sequences as a single sequence.

Parameters

...iterables: Array<Iterable<T>>

Returns

Iterable<T>