{"id":15434365,"url":"https://github.com/bartmelton/controlledloop","last_synced_at":"2025-03-17T16:21:26.110Z","repository":{"id":57206636,"uuid":"79263945","full_name":"bartmelton/ControlledLoop","owner":"bartmelton","description":"A javascript module for moving forward, backward, and in a non-linear fashion through an array or object one or more keys at a time.","archived":false,"fork":false,"pushed_at":"2017-03-27T10:35:43.000Z","size":43,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-11T16:41:03.760Z","etag":null,"topics":["iteration","iteration-over-objects","iterative-methods","iterator","javascript"],"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/bartmelton.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}},"created_at":"2017-01-17T19:33:38.000Z","updated_at":"2017-02-16T20:34:17.000Z","dependencies_parsed_at":"2022-09-11T07:01:17.818Z","dependency_job_id":null,"html_url":"https://github.com/bartmelton/ControlledLoop","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bartmelton%2FControlledLoop","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bartmelton%2FControlledLoop/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bartmelton%2FControlledLoop/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bartmelton%2FControlledLoop/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bartmelton","download_url":"https://codeload.github.com/bartmelton/ControlledLoop/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244066192,"owners_count":20392407,"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":["iteration","iteration-over-objects","iterative-methods","iterator","javascript"],"created_at":"2024-10-01T18:39:02.283Z","updated_at":"2025-03-17T16:21:26.085Z","avatar_url":"https://github.com/bartmelton.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# controlledLoop\nA javascript module for moving forward, backward, and in a non-linear fashion through an array or object one or more keys at a time.\n\n## Summary\nCreating a controlled-loop allows you to move through an array or object in many different ways\n\n  1. iterate similar to generators with `next()`\n  2. backup with `previous()`\n  3. run in bulk like a `forEach()` but with the ability to stop at any time\n  4. chunk or batch a group of items at a time\n  5. iterate over every nth item\n  6. iterate in reverse\n  7. reverse direction mid-flow\n  8. skip over items\n  9. goto a specific `key`\n  10. Set your own `keys` array to only use a subset of properties or to set the order\n  11. change the callback at any time\n\n\n\t### Homepage\n  [http://www.ozonecreations.com/projects/controlled-loop](http://www.ozonecreations.com/projects/controlled-loop)\n\n  ### Installing\n\n  #### GitHub\n  [https://github.com/bartmelton/ControlledLoop](https://github.com/bartmelton/ControlledLoop)\n\n  #### NPM\n  ```\n  npm install controlled-loop\n  ```\n\n  #### Bower\n  ```\n  bower install controlled-loop\n  ```\n\n\n\n  ### Exports:\n  1. It will export as an [AMD module](https://github.com/amdjs/amdjs-api/wiki/AMD#defineamd-property-) if available, otherwise it will try to export as a [CommonJS module](http://www.commonjs.org/)\n  2. If [Lodash](https://lodash.com/) or [Underscore](http://underscorejs.org/) are available, it adds as a mixin.\n  3. If none of the above options are available it falls back to a global `controlledLoop()` function attached to window, global, or this depending on which is available.\n\n  #### Node\n  ```\n  var controlledLoop = require(\"controlled-loop\").controlledLoop\n  ```\n  #### Lodash/Underscore\n  ```\n  _.controlledLoop()\n  ```\n  #### Default\n  ```\n  controlledLoop();\n  ```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbartmelton%2Fcontrolledloop","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbartmelton%2Fcontrolledloop","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbartmelton%2Fcontrolledloop/lists"}