{
  "name": "concat-stream",
  "version": "1.4.6",
  "description": "writable stream that concatenates strings or binary data and calls a callback with the result",
  "tags": [
    "stream",
    "simple",
    "util",
    "utility"
  ],
  "author": {
    "name": "Max Ogden",
    "email": "max@maxogden.com"
  },
  "repository": {
    "type": "git",
    "url": "http://github.com/maxogden/concat-stream.git"
  },
  "bugs": {
    "url": "http://github.com/maxogden/concat-stream/issues"
  },
  "engines": [
    "node >= 0.8"
  ],
  "main": "index.js",
  "scripts": {
    "test": "tape test/*.js test/server/*.js"
  },
  "license": "MIT",
  "dependencies": {
    "inherits": "~2.0.1",
    "typedarray": "~0.0.5",
    "readable-stream": "~1.1.9"
  },
  "devDependencies": {
    "tape": "~2.3.2"
  },
  "testling": {
    "files": "test/*.js",
    "browsers": [
      "ie/8..latest",
      "firefox/17..latest",
      "firefox/nightly",
      "chrome/22..latest",
      "chrome/canary",
      "opera/12..latest",
      "opera/next",
      "safari/5.1..latest",
      "ipad/6.0..latest",
      "iphone/6.0..latest",
      "android-browser/4.2..latest"
    ]
  },
  "readme": "# concat-stream\n\nWritable stream that concatenates strings or binary data and calls a callback with the result. Not a transform stream -- more of a stream sink.\n\n[![NPM](https://nodei.co/npm/concat-stream.png)](https://nodei.co/npm/concat-stream/)\n\n[![browser support](https://ci.testling.com/maxogden/concat-stream.png)](https://ci.testling.com/maxogden/concat-stream)\n\n### examples\n\n#### Buffers\n\n```js\nvar concat = require('concat-stream')\nvar fs = require('fs')\n    \nvar read = fs.createReadStream('readme.md')\nvar write = concat(function(data) {\n  // data is all of readme.md as a Buffer\n})\n    \nread.pipe(write)\n```\n\n#### Arrays\n\n```js\nvar write = concat(function(data) {})\nwrite.write([1,2,3])\nwrite.write([4,5,6])\nwrite.end()\n// data will be [1,2,3,4,5,6] in the above callback\n```\n\n#### Uint8Arrays\n\n```js\nvar write = concat(function(data) {})\nvar a = new Uint8Array(3)\na[0] = 97; a[1] = 98; a[2] = 99\nwrite.write(a)\nwrite.write('!')\nwrite.end(Buffer('!!1'))\n```\n\nSee `test/` for more examples\n\n# methods\n\n```js\nvar concat = require('concat-stream')\n```\n\n## var writable = concat(opts={}, cb)\n\nReturn a `writable` stream that will fire `cb(data)` with all of the data that\nwas written to the stream. Data can be written to `writable` as strings,\nBuffers, arrays of byte integers, and Uint8Arrays. \n\nBy default `concat-stream` will give you back the same data type as the type of the first buffer written to the stream. Use `opts.encoding` to set what format `data` should be returned as, e.g. if you if you don't want to rely on the built-in type checking or for some other reason.\n\n* `string` - get a string\n* `buffer` - get back a Buffer\n* `array` - get an array of byte integers\n* `uint8array`, `u8`, `uint8` - get back a Uint8Array\n* `object`, get back an array of Objects\n\nIf you don't specify an encoding, and the types can't be inferred (e.g. you write things that aren't int he list above), it will try to convert concat them into a `Buffer`.\n\n# license\n\nMIT LICENSE\n",
  "readmeFilename": "readme.md",
  "homepage": "https://github.com/maxogden/concat-stream",
  "_id": "concat-stream@1.4.6",
  "_shasum": "8cb736a556a32f020f1ddc82fa3448381c5e5cce",
  "_from": "concat-stream@^1.4.5",
  "_resolved": "https://registry.npmjs.org/concat-stream/-/concat-stream-1.4.6.tgz"
}
