Effect CommunityEC
Effect Community3y ago
6 replies
Tycho

Starting a Promise and Delaying its Execution

What is the equivalent to starting a promise but not waiting for it immediately? So with promises I can do:
async function () {
  const r0 = createLongRunningPromise()
  const r1 = await task2()
  const r2 = await task3()
  return {r1, r2, r0: await r0}
}
Was this page helpful?