effect-io-ai

Package: effect
Module: Sink

Sink.collectAllWhile

Accumulates incoming elements into a chunk as long as they verify predicate p.

Signature

declare const collectAllWhile: { <In, Out extends In>(refinement: Refinement<In, Out>): Sink<Chunk.Chunk<Out>, In, In>; <In>(predicate: Predicate<In>): Sink<Chunk.Chunk<In>, In, In>; }

Source

Since v2.0.0