@revideo/core / flow / join
Function: join()
Call Signature
join(…
tasks):ThreadGenerator
Defined in: flow/join.ts:21
Pause the current generator until all listed tasks are finished.
Parameters
tasks
A list of tasks to join.
Returns
Example
const task = yield generatorFunction();
// do something concurrently
yield* join(task);Call Signature
join(
all, …tasks):ThreadGenerator
Defined in: flow/join.ts:39
Pause the current generator until listed tasks are finished.
Parameters
all
boolean
Whether we should wait for all tasks or for at least one.
tasks
A list of tasks to join.
Returns
Example
const taskA = yield generatorFunctionA();
const taskB = yield generatorFunctionB();
// do something concurrently
// await any of the tasks
yield* join(false, taskA, taskB);