{"_id":"map-limit","_rev":"404078","name":"map-limit","description":"async.mapLimit's functionality available as a standalone npm module","dist-tags":{"latest":"0.0.1"},"maintainers":[{"name":"hughsk","email":"hughskennedy@gmail.com"}],"time":{"modified":"2021-08-04T04:42:42.000Z","created":"2014-02-07T05:33:04.029Z","0.0.1":"2014-08-07T22:48:46.178Z","0.0.0":"2014-02-07T05:33:04.029Z"},"users":{},"author":{"name":"Hugh Kennedy","email":"hughskennedy@gmail.com","url":"http://hughsk.io/"},"repository":{"type":"git","url":"git://github.com/hughsk/map-limit"},"versions":{"0.0.1":{"name":"map-limit","description":"async.mapLimit's functionality available as a standalone npm module","version":"0.0.1","main":"index.js","browser":"index.js","dependencies":{"once":"~1.3.0"},"devDependencies":{"tape":"~2.4.2"},"scripts":{"test":"node test"},"author":{"name":"Hugh Kennedy","email":"hughskennedy@gmail.com","url":"http://hughsk.io/"},"license":"MIT","repository":{"type":"git","url":"git://github.com/hughsk/map-limit"},"bugs":{"url":"https://github.com/hughsk/map-limit/issues"},"homepage":"https://github.com/hughsk/map-limit","keywords":["async","map","limit"],"gitHead":"54633d3dea9f407482ac62927ba3664a8cbc7f36","_id":"map-limit@0.0.1","_shasum":"eb7961031c0f0e8d001bf2d56fab685d58822f38","_from":".","_npmVersion":"1.4.23","_npmUser":{"name":"hughsk","email":"hughskennedy@gmail.com"},"maintainers":[{"name":"hughsk","email":"hughskennedy@gmail.com"}],"dist":{"shasum":"eb7961031c0f0e8d001bf2d56fab685d58822f38","size":2645,"noattachment":false,"key":"/map-limit/-/map-limit-0.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/map-limit/download/map-limit-0.0.1.tgz"},"directories":{},"publish_time":1407451726178,"_cnpm_publish_time":1407451726178,"_hasShrinkwrap":false},"0.0.0":{"name":"map-limit","description":"async.mapLimit's functionality available as a standalone npm module","version":"0.0.0","main":"index.js","browser":"index.js","dependencies":{"once":"~1.3.0"},"devDependencies":{"tape":"~2.4.2"},"scripts":{"test":"node test"},"author":{"name":"Hugh Kennedy","email":"hughskennedy@gmail.com","url":"http://hughsk.io/"},"license":"MIT","repository":{"type":"git","url":"git://github.com/hughsk/map-limit"},"bugs":{"url":"https://github.com/hughsk/map-limit/issues"},"homepage":"https://github.com/hughsk/map-limit","keywords":["async","map","limit"],"_id":"map-limit@0.0.0","dist":{"shasum":"b95e8efb78817825bd69af30b986abe23c18c74f","size":2640,"noattachment":false,"key":"/map-limit/-/map-limit-0.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/map-limit/download/map-limit-0.0.0.tgz"},"_from":".","_npmVersion":"1.3.25","_npmUser":{"name":"hughsk","email":"hughskennedy@gmail.com"},"maintainers":[{"name":"hughsk","email":"hughskennedy@gmail.com"}],"directories":{},"publish_time":1391751184029,"_cnpm_publish_time":1391751184029,"_hasShrinkwrap":false}},"readme":"# map-limit [![Flattr this!](https://api.flattr.com/button/flattr-badge-large.png)](https://flattr.com/submit/auto?user_id=hughskennedy&url=http://github.com/hughsk/map-limit&title=map-limit&description=hughsk/map-limit%20on%20GitHub&language=en_GB&tags=flattr,github,javascript&category=software)[![experimental](http://hughsk.github.io/stability-badges/dist/experimental.svg)](http://github.com/hughsk/stability-badges) #\n\n[async.mapLimit](https://github.com/caolan/async#maplimitarr-limit-iterator-callback)'s\nfunctionality available as a standalone npm module.\n\nI often find myself pulling in [async](http://github.com/caolan/async) for this\nmethod alone, so in the spirit of breaking things into smaller pieces here's\nthat method as a single thing you can require.\n\n## Usage ##\n\n[![map-limit](https://nodei.co/npm/map-limit.png?mini=true)](https://nodei.co/npm/map-limit)\n\n### `mapLimit(arr, limit, iterator, callback)` ###\n\nThe same as map only no more than \"limit\" iterators will be simultaneously\nrunning at any time.\n\nNote that the items are not processed in batches, so there is no guarantee\nthat the first \"limit\" iterator functions will complete before any others are\nstarted.\n\n#### Arguments ####\n\n* **arr** - An array to iterate over.\n* **limit** - The maximum number of iterators to run at any time.\n* **iterator(item, callback)** - A function to apply to each item in the array. The iterator is passed a callback(err, transformed) which must be called once it has completed with an error (which can be null) and a transformed item.\n* **callback(err, results)** - A callback which is called after all the iterator functions have finished, or an error has occurred. Results is an array of the transformed items from the original array.\n\n## License ##\n\nMIT. See [LICENSE.md](http://github.com/hughsk/map-limit/blob/master/LICENSE.md) for details.\n","_attachments":{},"homepage":"https://github.com/hughsk/map-limit","bugs":{"url":"https://github.com/hughsk/map-limit/issues"},"license":"MIT"}