Bakhtina Sofya b84cb877be 1st comm il y a 2 semaines
..
dist b84cb877be 1st comm il y a 2 semaines
internal b84cb877be 1st comm il y a 2 semaines
CHANGELOG.md b84cb877be 1st comm il y a 2 semaines
LICENSE b84cb877be 1st comm il y a 2 semaines
README.md b84cb877be 1st comm il y a 2 semaines
all.js b84cb877be 1st comm il y a 2 semaines
allLimit.js b84cb877be 1st comm il y a 2 semaines
allSeries.js b84cb877be 1st comm il y a 2 semaines
any.js b84cb877be 1st comm il y a 2 semaines
anyLimit.js b84cb877be 1st comm il y a 2 semaines
anySeries.js b84cb877be 1st comm il y a 2 semaines
apply.js b84cb877be 1st comm il y a 2 semaines
applyEach.js b84cb877be 1st comm il y a 2 semaines
applyEachSeries.js b84cb877be 1st comm il y a 2 semaines
asyncify.js b84cb877be 1st comm il y a 2 semaines
auto.js b84cb877be 1st comm il y a 2 semaines
autoInject.js b84cb877be 1st comm il y a 2 semaines
bower.json b84cb877be 1st comm il y a 2 semaines
cargo.js b84cb877be 1st comm il y a 2 semaines
compose.js b84cb877be 1st comm il y a 2 semaines
concat.js b84cb877be 1st comm il y a 2 semaines
concatLimit.js b84cb877be 1st comm il y a 2 semaines
concatSeries.js b84cb877be 1st comm il y a 2 semaines
constant.js b84cb877be 1st comm il y a 2 semaines
detect.js b84cb877be 1st comm il y a 2 semaines
detectLimit.js b84cb877be 1st comm il y a 2 semaines
detectSeries.js b84cb877be 1st comm il y a 2 semaines
dir.js b84cb877be 1st comm il y a 2 semaines
doDuring.js b84cb877be 1st comm il y a 2 semaines
doUntil.js b84cb877be 1st comm il y a 2 semaines
doWhilst.js b84cb877be 1st comm il y a 2 semaines
during.js b84cb877be 1st comm il y a 2 semaines
each.js b84cb877be 1st comm il y a 2 semaines
eachLimit.js b84cb877be 1st comm il y a 2 semaines
eachOf.js b84cb877be 1st comm il y a 2 semaines
eachOfLimit.js b84cb877be 1st comm il y a 2 semaines
eachOfSeries.js b84cb877be 1st comm il y a 2 semaines
eachSeries.js b84cb877be 1st comm il y a 2 semaines
ensureAsync.js b84cb877be 1st comm il y a 2 semaines
every.js b84cb877be 1st comm il y a 2 semaines
everyLimit.js b84cb877be 1st comm il y a 2 semaines
everySeries.js b84cb877be 1st comm il y a 2 semaines
filter.js b84cb877be 1st comm il y a 2 semaines
filterLimit.js b84cb877be 1st comm il y a 2 semaines
filterSeries.js b84cb877be 1st comm il y a 2 semaines
find.js b84cb877be 1st comm il y a 2 semaines
findLimit.js b84cb877be 1st comm il y a 2 semaines
findSeries.js b84cb877be 1st comm il y a 2 semaines
foldl.js b84cb877be 1st comm il y a 2 semaines
foldr.js b84cb877be 1st comm il y a 2 semaines
forEach.js b84cb877be 1st comm il y a 2 semaines
forEachLimit.js b84cb877be 1st comm il y a 2 semaines
forEachOf.js b84cb877be 1st comm il y a 2 semaines
forEachOfLimit.js b84cb877be 1st comm il y a 2 semaines
forEachOfSeries.js b84cb877be 1st comm il y a 2 semaines
forEachSeries.js b84cb877be 1st comm il y a 2 semaines
forever.js b84cb877be 1st comm il y a 2 semaines
groupBy.js b84cb877be 1st comm il y a 2 semaines
groupByLimit.js b84cb877be 1st comm il y a 2 semaines
groupBySeries.js b84cb877be 1st comm il y a 2 semaines
index.js b84cb877be 1st comm il y a 2 semaines
inject.js b84cb877be 1st comm il y a 2 semaines
log.js b84cb877be 1st comm il y a 2 semaines
map.js b84cb877be 1st comm il y a 2 semaines
mapLimit.js b84cb877be 1st comm il y a 2 semaines
mapSeries.js b84cb877be 1st comm il y a 2 semaines
mapValues.js b84cb877be 1st comm il y a 2 semaines
mapValuesLimit.js b84cb877be 1st comm il y a 2 semaines
mapValuesSeries.js b84cb877be 1st comm il y a 2 semaines
memoize.js b84cb877be 1st comm il y a 2 semaines
nextTick.js b84cb877be 1st comm il y a 2 semaines
package.json b84cb877be 1st comm il y a 2 semaines
parallel.js b84cb877be 1st comm il y a 2 semaines
parallelLimit.js b84cb877be 1st comm il y a 2 semaines
priorityQueue.js b84cb877be 1st comm il y a 2 semaines
queue.js b84cb877be 1st comm il y a 2 semaines
race.js b84cb877be 1st comm il y a 2 semaines
reduce.js b84cb877be 1st comm il y a 2 semaines
reduceRight.js b84cb877be 1st comm il y a 2 semaines
reflect.js b84cb877be 1st comm il y a 2 semaines
reflectAll.js b84cb877be 1st comm il y a 2 semaines
reject.js b84cb877be 1st comm il y a 2 semaines
rejectLimit.js b84cb877be 1st comm il y a 2 semaines
rejectSeries.js b84cb877be 1st comm il y a 2 semaines
retry.js b84cb877be 1st comm il y a 2 semaines
retryable.js b84cb877be 1st comm il y a 2 semaines
select.js b84cb877be 1st comm il y a 2 semaines
selectLimit.js b84cb877be 1st comm il y a 2 semaines
selectSeries.js b84cb877be 1st comm il y a 2 semaines
seq.js b84cb877be 1st comm il y a 2 semaines
series.js b84cb877be 1st comm il y a 2 semaines
setImmediate.js b84cb877be 1st comm il y a 2 semaines
some.js b84cb877be 1st comm il y a 2 semaines
someLimit.js b84cb877be 1st comm il y a 2 semaines
someSeries.js b84cb877be 1st comm il y a 2 semaines
sortBy.js b84cb877be 1st comm il y a 2 semaines
timeout.js b84cb877be 1st comm il y a 2 semaines
times.js b84cb877be 1st comm il y a 2 semaines
timesLimit.js b84cb877be 1st comm il y a 2 semaines
timesSeries.js b84cb877be 1st comm il y a 2 semaines
transform.js b84cb877be 1st comm il y a 2 semaines
tryEach.js b84cb877be 1st comm il y a 2 semaines
unmemoize.js b84cb877be 1st comm il y a 2 semaines
until.js b84cb877be 1st comm il y a 2 semaines
waterfall.js b84cb877be 1st comm il y a 2 semaines
whilst.js b84cb877be 1st comm il y a 2 semaines
wrapSync.js b84cb877be 1st comm il y a 2 semaines

README.md

Async Logo

Build Status via Travis CI NPM version Coverage Status libhive - Open source examples jsDelivr Hits

Async is a utility module which provides straight-forward, powerful functions for working with asynchronous JavaScript. Although originally designed for use with Node.js and installable via npm install --save async, it can also be used directly in the browser.

This version of the package is optimized for the Node.js environment. If you use Async with webpack, install async-es instead.

For Documentation, visit https://caolan.github.io/async/

For Async v1.5.x documentation, go HERE

// for use with Node-style callbacks...
var async = require("async");

var obj = {dev: "/dev.json", test: "/test.json", prod: "/prod.json"};
var configs = {};

async.forEachOf(obj, (value, key, callback) => {
    fs.readFile(__dirname + value, "utf8", (err, data) => {
        if (err) return callback(err);
        try {
            configs[key] = JSON.parse(data);
        } catch (e) {
            return callback(e);
        }
        callback();
    });
}, err => {
    if (err) console.error(err.message);
    // configs is now a map of JSON data
    doSomethingWith(configs);
});
var async = require("async");

// ...or ES2017 async functions
async.mapLimit(urls, 5, async function(url) {
    const response = await fetch(url)
    return response.body
}, (err, results) => {
    if (err) throw err
    // results is now an array of the response bodies
    console.log(results)
})