effect-io-ai

Package: effect
Module: Stream

Stream.unfoldChunk

Creates a stream by peeling off the “layers” of a value of type S.

Signature

declare const unfoldChunk: <S, A>(s: S, f: (s: S) => Option.Option<readonly [Chunk.Chunk<A>, S]>) => Stream<A>

Source

Since v2.0.0