{"id":18338870,"url":"https://github.com/tableflip/async-each-series-throttle","last_synced_at":"2025-04-09T20:36:04.191Z","repository":{"id":72910265,"uuid":"100611244","full_name":"tableflip/async-each-series-throttle","owner":"tableflip","description":"Iterate through items in series but throttle iteratee execution","archived":false,"fork":false,"pushed_at":"2018-01-23T08:54:02.000Z","size":22,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-15T12:46:56.408Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tableflip.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-08-17T14:18:07.000Z","updated_at":"2018-01-18T15:01:03.000Z","dependencies_parsed_at":"2023-05-26T01:15:24.053Z","dependency_job_id":null,"html_url":"https://github.com/tableflip/async-each-series-throttle","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tableflip%2Fasync-each-series-throttle","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tableflip%2Fasync-each-series-throttle/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tableflip%2Fasync-each-series-throttle/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tableflip%2Fasync-each-series-throttle/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tableflip","download_url":"https://codeload.github.com/tableflip/async-each-series-throttle/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248108470,"owners_count":21049137,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-05T20:15:48.601Z","updated_at":"2025-04-09T20:36:04.171Z","avatar_url":"https://github.com/tableflip.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# async-each-series-throttle [![Build Status](https://travis-ci.org/tableflip/async-each-series-throttle.svg?branch=master)](https://travis-ci.org/tableflip/async-each-series-throttle) [![dependencies Status](https://david-dm.org/tableflip/async-each-series-throttle/status.svg)](https://david-dm.org/tableflip/async-each-series-throttle)\n\nIterate through items in series but throttle iteratee execution\n\n## Usage\n\n```js\nimport eachSeriesThrottle from 'async-each-series-throttle'\n\nconst items = [0, 1, 2, 3, 4]\n\n// Number in ms to throttle calls to iteratee\nconst wait = 1000\n\n// Called only once every ~1000ms at maximum\nconst iteratee = (item, cb) =\u003e {\n  // Do some async work and callback when done\n  //\n  // If this takes _more than_ 1000ms then iteratee will be called again\n  // immediately after cb is called.\n  //\n  // If this takes _less than_ 1000ms then iteratee will be called again after\n  // ~1000ms have elapsed since the last time it was called.\n  setTimeout(() =\u003e cb(null, item + 1), 500)\n}\n\n// Optional callback after everything is done\nconst callback = (err, results) =\u003e {\n  // All done, after ~4000ms or more\n  // results is [1, 2, 3, 4, 5]\n}\n\neachSeriesThrottle(items, iteratee, wait, callback)\n```\n\n## Contribute\n\nFeel free to dive in! [Open an issue](https://github.com/tableflip/mem-storage-area/issues/new) or submit PRs.\n\n## License\n\n[MIT](LICENSE) © Oli Evans and Alan Shaw\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftableflip%2Fasync-each-series-throttle","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftableflip%2Fasync-each-series-throttle","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftableflip%2Fasync-each-series-throttle/lists"}