{"_id":"pull-offset-limit","_rev":"4652859","name":"pull-offset-limit","description":"A pull-stream that filters until X elements, and stops streaming after Y elements.","dist-tags":{"latest":"1.1.1"},"maintainers":[{"name":"jdvorak","email":""}],"time":{"modified":"2026-04-10T20:50:01.000Z","created":"2017-04-09T18:44:43.185Z","1.1.1":"2017-04-13T05:34:53.939Z","1.1.0":"2017-04-09T18:52:57.463Z","1.0.0":"2017-04-09T18:44:43.185Z"},"users":{},"author":{"name":"John Dvorak","email":"john@johnsdvorak.com"},"repository":{"type":"git","url":"git+https://github.com/jdvorak/pull-offset-limit.git"},"versions":{"1.1.1":{"name":"pull-offset-limit","version":"1.1.1","description":"A pull-stream that filters until X elements, and stops streaming after Y elements.","main":"index.js","scripts":{"deps":"dependency-check . && dependency-check . --extra --no-dev","test":"standard && npm run deps && NODE_ENV=test node test","test:cov":"standard && npm run deps && NODE_ENV=test istanbul cover test.js"},"repository":{"type":"git","url":"git+https://github.com/jdvorak/pull-offset-limit.git"},"keywords":["pull-stream","limit","offset","pagination"],"license":"MIT","dependencies":{"pull-abortable":"^4.1.0","pull-stream":"^3.5.0"},"devDependencies":{"dependency-check":"^2.8.0","istanbul":"^0.4.5","standard":"^8.6.0","tape":"^4.6.3"},"bugs":{"url":"https://github.com/jdvorak/pull-offset-limit/issues"},"homepage":"https://github.com/jdvorak/pull-offset-limit#readme","author":{"name":"John Dvorak","email":"john@johnsdvorak.com"},"gitHead":"aabc95c0377c91ef16d427338f95cb50017e9174","_id":"pull-offset-limit@1.1.1","_shasum":"48193d237a7e29ea13e3efc4d48e4a3c1d6c6971","_from":".","_npmVersion":"3.10.8","_nodeVersion":"6.9.1","_npmUser":{"name":"jdvorak","email":"twelvetwo@gmail.com"},"dist":{"shasum":"48193d237a7e29ea13e3efc4d48e4a3c1d6c6971","size":2956,"noattachment":false,"key":"/pull-offset-limit/-/pull-offset-limit-1.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/pull-offset-limit/download/pull-offset-limit-1.1.1.tgz"},"maintainers":[{"name":"jdvorak","email":""}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/pull-offset-limit-1.1.1.tgz_1492061692052_0.8051171756815165"},"directories":{},"publish_time":1492061693939,"_hasShrinkwrap":false,"_cnpm_publish_time":1492061693939,"_cnpmcore_publish_time":"2021-12-16T20:51:18.959Z"},"1.1.0":{"name":"pull-offset-limit","version":"1.1.0","description":"A pull-stream that filters until X elements, and stops streaming after Y elements.","main":"index.js","scripts":{"deps":"dependency-check . && dependency-check . --extra --no-dev","test":"standard && npm run deps && NODE_ENV=test node test","test:cov":"standard && npm run deps && NODE_ENV=test istanbul cover test.js"},"repository":{"type":"git","url":"git+https://github.com/jdvorak/pull-offset-limit.git"},"keywords":["pull-stream","limit","offset","pagination"],"license":"MIT","dependencies":{"pull-abortable":"^4.1.0","pull-stream":"^3.5.0"},"devDependencies":{"dependency-check":"^2.8.0","istanbul":"^0.4.5","standard":"^8.6.0","tape":"^4.6.3"},"bugs":{"url":"https://github.com/jdvorak/pull-offset-limit/issues"},"homepage":"https://github.com/jdvorak/pull-offset-limit#readme","author":{"name":"John Dvorak","email":"john@johnsdvorak.com"},"gitHead":"a1abf142b8cda9de87005869083928ffd0d2103f","_id":"pull-offset-limit@1.1.0","_shasum":"8c5f9b3f568b5656a6fb470ef779bcbc7a802532","_from":".","_npmVersion":"3.10.8","_nodeVersion":"6.9.1","_npmUser":{"name":"jdvorak","email":"twelvetwo@gmail.com"},"dist":{"shasum":"8c5f9b3f568b5656a6fb470ef779bcbc7a802532","size":2952,"noattachment":false,"key":"/pull-offset-limit/-/pull-offset-limit-1.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/pull-offset-limit/download/pull-offset-limit-1.1.0.tgz"},"maintainers":[{"name":"jdvorak","email":""}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/pull-offset-limit-1.1.0.tgz_1491763977198_0.07911797100678086"},"directories":{},"publish_time":1491763977463,"_hasShrinkwrap":false,"_cnpm_publish_time":1491763977463,"_cnpmcore_publish_time":"2021-12-16T20:51:19.144Z"},"1.0.0":{"name":"pull-offset-limit","version":"1.0.0","description":"A pull-stream that filters until X elements, and stops streaming after Y elements.","main":"index.js","scripts":{"deps":"dependency-check . && dependency-check . --extra --no-dev","test":"standard && npm run deps && NODE_ENV=test node test","test:cov":"standard && npm run deps && NODE_ENV=test istanbul cover test.js"},"repository":{"type":"git","url":"git+https://github.com/jdvorak/pull-offset-limit.git"},"keywords":["pull-stream","limit","offset","pagination"],"license":"MIT","dependencies":{"pull-abortable":"^4.1.0","pull-stream":"^3.5.0"},"devDependencies":{"dependency-check":"^2.8.0","istanbul":"^0.4.5","standard":"^8.6.0","tape":"^4.6.3"},"gitHead":"1db59de3f580a3d66b04176549e99e231c3ee42e","bugs":{"url":"https://github.com/jdvorak/pull-offset-limit/issues"},"homepage":"https://github.com/jdvorak/pull-offset-limit#readme","_id":"pull-offset-limit@1.0.0","_shasum":"98cb7c8a2b7ecb6a925e90d7ece1c0a856764cc2","_from":".","_npmVersion":"3.10.8","_nodeVersion":"6.9.1","_npmUser":{"name":"jdvorak","email":"twelvetwo@gmail.com"},"dist":{"shasum":"98cb7c8a2b7ecb6a925e90d7ece1c0a856764cc2","size":2857,"noattachment":false,"key":"/pull-offset-limit/-/pull-offset-limit-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/pull-offset-limit/download/pull-offset-limit-1.0.0.tgz"},"maintainers":[{"name":"jdvorak","email":""}],"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/pull-offset-limit-1.0.0.tgz_1491763482517_0.21254620584659278"},"directories":{},"publish_time":1491763483185,"_hasShrinkwrap":false,"_cnpm_publish_time":1491763483185,"_cnpmcore_publish_time":"2021-12-16T20:51:19.342Z"}},"readme":"# pull-offset-limit\n[![npm version][2]][3] [![build status][4]][5] [![test coverage][6]][7]\n[![downloads][8]][9] [![js-standard-style][10]][11]\n\n A pull-stream that filters until X elements, and stops streaming after Y elements. Useful for pagination purposes.\n\n## Usage\n```js\nconst pull = require('pull-stream')\nconst split = require('pull-split')\nconst offsetLimit = require('pull-offset-limit')\n \npull(\n  textStream, // some text stream\n  split(), // split on new lines\n  offsetLimit(5, 20), // after 5 lines, take 20\n  output\n)\n\n```\n\n## API\n### \n\n### `offsetLimit = require('pull-offset-limit')(offset, limit, onLimit)`\nCreate a new offsetLimit through stream.\n- __offset:__ if set, filters stream until offset is reached\n- __limit:__ if set, stops stream when limit is reached\n- __onLimit:__ if set, runs when limit is reached\n\n## Installation\n```sh\n$ npm install pull-offset-limit\n```\n\n## License\n[MIT](https://tldrlegal.com/license/mit-license)\n\n[1]: https://nodejs.org/api/documentation.html#documentation_stability_index\n[2]: https://img.shields.io/npm/v/pull-offset-limit.svg?style=flat-square\n[3]: https://npmjs.org/package/pull-offset-limit\n[4]: https://img.shields.io/travis/JDvorak/pull-offset-limit/master.svg?style=flat-square\n[5]: https://travis-ci.org/JDvorak/pull-offset-limit\n[6]: https://img.shields.io/codecov/c/github/JDvorak/pull-offset-limit/master.svg?style=flat-square\n[7]: https://codecov.io/github/JDvorak/pull-offset-limit\n[8]: http://img.shields.io/npm/dm/pull-offset-limit.svg?style=flat-square\n[9]: https://npmjs.org/package/pull-offset-limit\n[10]: https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat-square\n[11]: https://github.com/feross/standard\n","_attachments":{},"homepage":"https://github.com/jdvorak/pull-offset-limit#readme","bugs":{"url":"https://github.com/jdvorak/pull-offset-limit/issues"},"license":"MIT"}