Skip to content

TypeScript API / laikacms/core / LaikaTask / drainWithValue

Function: drainWithValue() ​

ts
function drainWithValue<A, R>(self, onChunk): Effect<A, LaikaError<ErrorCode, number>, R>;

Low-level: drain a LaikaTask invoking onChunk per chunk; return the resolved value (Channel's OutDone).

Type Parameters ​

Type Parameter
A
R

Parameters ​

ParameterType
selfLaikaTask<A, R>
onChunk(chunk) => Effect<void>

Returns ​

Effect<A, LaikaError<ErrorCode, number>, R>

Released under the MIT License.