Hyperlinkv0.8.0-beta.28

Effect

Effect.awaitAllChildrenconsteffect/Effect.ts:8731
<A, E, R>(self: Effect<A, E, R>): Effect<A, E, R>

Waits for all child fibers forked by this effect to complete before this effect completes.

When to use

Use to let an effect start child work concurrently while still delaying its own completion until that child work is done.

Gotchas

Child fibers that already exist before the wrapped effect starts are not awaited.

Source effect/Effect.ts:87311 lines
export const awaitAllChildren: <A, E, R>(self: Effect<A, E, R>) => Effect<A, E, R> = internal.awaitAllChildren