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

x/fun/mod.ts>iterable.collect

A collection of algebraic data types, lenses, and schemables based on a light weight higher kinded type implementation. Written for deno.
Latest
function iterable.collect
import { iterable } from "https://deno.land/x/fun@v2.0.0/mod.ts";
const { collect } = iterable;

Collect all values of an iterable into an array. WARNING: If the iterable is infinite then this will cause the program to hang indefinitely.

Parameters

ta: Iterable<A>

Returns

ReadonlyArray<A>