for-await
A tiny JavaScript utility to write for-await.
Install
npm install --save for-await
const forAwait = ;
Usage
;
API
forAwait( fn:function ).of( source:asyncIterable|syncIterable ):Promise<undefined>
fn
is called with item
, index
, source
.
of
returns a Promise that resolves when iteration has finished.