Sequential or concurrent

Independent asynchronous operations can run one after the other (sequential) or at the same time (concurrent). Several successive awaits are sequential and add up their durations. Starting all the promises first and then awaiting them together reduces the total time, provided they don't depend on each other.

Example

const a = charger('a')
const b = charger('b')
const [ra, rb] = [await a, await b]

Related concepts

The whole glossary