This repository has been archived on 2022-07-06. You can view files and clone it, but cannot push or open issues or pull requests.
websocket-webcam/node_modules/jsftp/node_modules/event-stream/node_modules/from/package.json

37 lines
1.5 KiB
JSON

{
"name": "from",
"version": "0.1.3",
"description": "Easy way to make a Readable Stream",
"main": "index.js",
"scripts": {
"test": "asynct test/*.js"
},
"repository": {
"type": "git",
"url": "git://github.com/dominictarr/from.git"
},
"keywords": [
"stream",
"streams",
"readable",
"easy"
],
"devDependencies": {
"asynct": "1",
"stream-spec": "0",
"assertions": "~2.3.0"
},
"author": {
"name": "Dominic Tarr",
"email": "dominic.tarr@gmail.com",
"url": "dominictarr.com"
},
"license": "MIT",
"readme": "# from\n\nAn easy way to create a `readable Stream`.\n\n## from(function getChunk(count, next))\n\nfrom takes a `getChunk` function and returns a stream. \n\n`getChunk` is called again and again, after each time the user calls `next()`, \nuntil the user emits `'end'`\n\nif `pause()` is called, the `getChunk` won't be called again untill `resume()` is called.\n\n\n```js\nvar from = require('from')\n\nvar stream = \n from(function getChunk(count, next) {\n //do some sort of data\n this.emit('data', whatever)\n \n if(itsOver)\n this.emit('end')\n\n //ready to handle the next chunk\n next()\n //or, if it's sync:\n return true \n })\n```\n\n## from(array)\n\nfrom also takes an `Array` whose elements it emits one after another.\n\n## License\nMIT / Apache2\n",
"_id": "from@0.1.3",
"dist": {
"shasum": "0ac5c9c9018c3f249f72e92396f3e5f25aa6fdbd"
},
"_from": "from@~0"
}