{"versions":{"1.1.0":{"name":"async-throttle","version":"1.1.0","license":"MIT","repository":{"type":"git","url":"git+https://github.com/zeit/async-throttle.git"},"files":["index.js"],"scripts":{"test":"xo && ava","example":"async-node example"},"description":"Throttle asynchronous Promise-based tasks","devDependencies":{"async-to-gen":"1.1.3","ava":"0.16.0","babel-eslint":"7.0.0","cheerio":"0.22.0","node-fetch":"1.6.3","then-sleep":"1.0.1","xo":"^0.17.0"},"ava":{"files":["test.js"],"require":"async-to-gen/register"},"xo":{"esnext":true,"space":true,"semicolon":false},"gitHead":"105c7e5842dd2f2dc2c25195f422df6fc6cf9dd7","bugs":{"url":"https://github.com/zeit/async-throttle/issues"},"homepage":"https://github.com/zeit/async-throttle#readme","_id":"async-throttle@1.1.0","_shasum":"229e7f3fa7a2a797e86f360e6309a08224d4fa7a","_from":".","_npmVersion":"4.0.5","_nodeVersion":"7.4.0","_npmUser":{"name":"anonymous","email":"nathan@tootallnate.net"},"dist":{"shasum":"229e7f3fa7a2a797e86f360e6309a08224d4fa7a","size":2002,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/async-throttle/-/async-throttle-1.1.0.tgz","integrity":"sha512-t5kQ/BRlYTNG2GsQue48DeKByahFGGHtC8w7LCEl1sGHbAgpthKXX6U2GL1t6xI89rWxCDc/xzEOW/8ObrZH0Q=="},"maintainers":[{"name":"anonymous","email":"rauchg@gmail.com"},{"name":"anonymous","email":"nathan@tootallnate.net"}],"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/async-throttle-1.1.0.tgz_1487268840287_0.34931315714493394"},"directories":{},"publish_time":1487268842125,"_hasShrinkwrap":false,"_cnpm_publish_time":1487268842125,"_cnpmcore_publish_time":"2021-12-16T15:43:20.077Z","contributors":[]},"1.0.0":{"name":"async-throttle","version":"1.0.0","license":"MIT","repository":{"type":"git","url":"git+https://github.com/zeit/async-throttle.git"},"files":["index.js"],"scripts":{"test":"xo && ava","example":"async-node example"},"description":"Throttle asynchronous Promise-based tasks","devDependencies":{"async-to-gen":"1.1.3","ava":"0.16.0","babel-eslint":"7.0.0","cheerio":"0.22.0","node-fetch":"1.6.3","then-sleep":"1.0.1","xo":"^0.17.0"},"ava":{"files":["test.js"],"require":"async-to-gen/register"},"xo":{"esnext":true,"space":true,"semicolon":false},"gitHead":"100871c19e24146ad3fc71d4e3a80709c03643c4","bugs":{"url":"https://github.com/zeit/async-throttle/issues"},"homepage":"https://github.com/zeit/async-throttle#readme","_id":"async-throttle@1.0.0","_shasum":"eaf533ba73b4b89d7c14ead3af18a130e2a6a467","_from":".","_npmVersion":"3.10.8","_nodeVersion":"6.9.1","_npmUser":{"name":"anonymous","email":"nathan@tootallnate.net"},"dist":{"shasum":"eaf533ba73b4b89d7c14ead3af18a130e2a6a467","size":1874,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/async-throttle/-/async-throttle-1.0.0.tgz","integrity":"sha512-0CaDhy7Y/YRog8ov/M5bdqlKsaR6jWcHVCXMHmVsPeviLU9k2jx8LIcg9VfsT3nomZ9M3xySp+irDnLkB1pI8Q=="},"maintainers":[{"name":"anonymous","email":"rauchg@gmail.com"},{"name":"anonymous","email":"nathan@tootallnate.net"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/async-throttle-1.0.0.tgz_1477505665894_0.945793193532154"},"directories":{},"publish_time":1477505666136,"_hasShrinkwrap":false,"_cnpm_publish_time":1477505666136,"_cnpmcore_publish_time":"2021-12-16T15:43:20.318Z","contributors":[]},"0.0.1":{"name":"async-throttle","version":"0.0.1","license":"MIT","repository":{"type":"git","url":"git+https://github.com/zeit/async-throttle.git"},"files":["index.js"],"description":"Throttle asynchronous Promise-based tasks","devDependencies":{"ava":"0.16.0","async-to-gen":"1.1.3","babel-eslint":"7.0.0","cheerio":"0.22.0","eslint":"3.6.1","eslint-config-standard":"6.2.0","eslint-plugin-promise":"2.0.1","eslint-plugin-standard":"2.0.1","node-fetch":"1.6.3","then-sleep":"1.0.1"},"eslintConfig":{"extends":"standard","parser":"babel-eslint"},"ava":{"files":["test.js"],"require":"async-to-gen/register"},"gitHead":"24b14973be34310e1e6fc48da7706d86cda5ad59","bugs":{"url":"https://github.com/zeit/async-throttle/issues"},"homepage":"https://github.com/zeit/async-throttle#readme","_id":"async-throttle@0.0.1","scripts":{},"_shasum":"5f48d6d9967e36c49d209f134bddab21ed062daf","_from":".","_npmVersion":"3.10.3","_nodeVersion":"6.5.0","_npmUser":{"name":"anonymous","email":"rauchg@gmail.com"},"dist":{"shasum":"5f48d6d9967e36c49d209f134bddab21ed062daf","size":1320,"noattachment":false,"tarball":"http://123.232.10.234:8212/nexus/content/groups/npm-public/async-throttle/-/async-throttle-0.0.1.tgz","integrity":"sha512-C+TkRMnTMNJXo/Oy0gJ3xlHq3FgAzJwJ09hnT6RM0l1iIhK7UmL2eTodqaWa8Fc6F2mqN2HXFAYxohjgBDioVw=="},"maintainers":[{"name":"anonymous","email":"rauchg@gmail.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/async-throttle-0.0.1.tgz_1475263780520_0.34514320991002023"},"directories":{},"publish_time":1475263780746,"_hasShrinkwrap":false,"_cnpm_publish_time":1475263780746,"_cnpmcore_publish_time":"2021-12-16T15:43:20.505Z","contributors":[]}},"dist-tags":{"latest":"1.1.0"},"name":"async-throttle","time":{"created":"2022-01-26T20:56:43.181Z","modified":"2022-01-26T20:56:43.181Z","1.1.0":"2017-02-16T18:14:02.125Z","1.0.0":"2016-10-26T18:14:26.136Z","0.0.1":"2016-09-30T19:29:40.746Z"},"readme":"# async-throttle\n\n[![Build Status](https://travis-ci.org/zeit/async-throttle.svg?branch=master)](https://travis-ci.org/zeit/async-throttle)\n[![XO code style](https://img.shields.io/badge/code_style-XO-5ed9c7.svg)](https://github.com/sindresorhus/xo)\n[![Slack Channel](https://zeit-slackin.now.sh/badge.svg)](https://zeit.chat/)\n\nThrottling made simple, easy, async.\n\n## How to use\n\nThis example fetches the `<title>` tag of the supplied websites,\nbut it processes a maximum of **two at a time**.\n\n<p align=\"center\">\n  <img src=\"https://cldup.com/QstcrynRNT.gif\" />\n</p>\n\n```js\n// deps\nconst fetch = require('node-fetch')\nconst createThrottle = require('async-throttle')\nconst cheerio = require('cheerio').load\n\n// code\nconst throttle = createThrottle(2)\nconst urls = ['https://zeit.co', 'https://google.com', /* … */]\nPromise.all(urls.map((url) => throttle(async () => {\n  console.log('Processing', url)\n  const res = await fetch(url)\n  const data = await res.text()\n  const $ = cheerio(data)\n  return $('title').text()\n})))\n.then((titles) => console.log('Titles:', titles))\n```\n\nTo run this example:\n\n```\ngit clone git@github.com:zeit/async-throttle\ncd async-throttle\nnpm install\nnpm run example\n```","users":{}}