Web features explorer

Async iterators and the for await..of loop

Widely available
Tags: javascript Groups: JavaScript > Iterators

Asynchronous iterator objects, such as those returned by promises or generator functions, are iterable with the for await .. of loop. To learn more, see AsyncIterator, AsyncIterator.prototype[Symbol.asyncIterator](), Symbol.asyncIterator, for await...of at MDN.

Compatibility