{
  "name": "eventsource",
  "version": "0.0.10",
  "description": "W3C compliant EventSource client for Node.js",
  "keywords": [
    "eventsource",
    "http",
    "streaming",
    "sse"
  ],
  "homepage": "http://github.com/aslakhellesoy/eventsource-node",
  "author": {
    "name": "Aslak Hellesøy",
    "email": "aslak.hellesoy@gmail.com"
  },
  "contributors": [
    {
      "name": "Aslak Hellesøy",
      "email": "aslak.hellesoy@gmail.com"
    },
    {
      "name": "Einar Otto Stangvik",
      "email": "einaros+gh@gmail.com"
    },
    {
      "name": "Dan North",
      "email": "tastapod@gmail.com"
    },
    {
      "name": "Scott Moak",
      "email": "scott.moak@mybrainoncode.com"
    },
    {
      "name": "William Wicks"
    },
    {
      "name": "Devon Adkisson"
    },
    {
      "name": "FrozenCow",
      "email": "frozencow@gmail.com"
    }
  ],
  "repository": {
    "type": "git",
    "url": "git://github.com/aslakhellesoy/eventsource-node.git"
  },
  "bugs": {
    "url": "http://github.com/aslakhellesoy/eventsource-node/issues"
  },
  "directories": {
    "lib": "./lib"
  },
  "main": "./lib/eventsource",
  "licenses": [
    {
      "type": "MIT",
      "url": "http://github.com/aslakhellesoy/eventsource-node/raw/master/LICENSE"
    }
  ],
  "devDependencies": {
    "mocha": "~1.9.0",
    "jison": "~0.4.4"
  },
  "scripts": {
    "test": "make run-tests"
  },
  "engines": {
    "node": ">=0.6.0"
  },
  "readme": "# EventSource [![Build Status](https://secure.travis-ci.org/aslakhellesoy/eventsource-node.png)](http://travis-ci.org/aslakhellesoy/eventsource-node) [![Dependencies](https://david-dm.org/aslakhellesoy/eventsource-node.png)](https://david-dm.org/aslakhellesoy/eventsource-node) [![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/aslakhellesoy/eventsource-node/trend.png)](https://bitdeli.com/free \"Bitdeli Badge\")\n\n\n[![NPM](https://nodei.co/npm/eventsource.png?stars&downloads)](https://nodei.co/npm/eventsource/) \n[![NPM](https://nodei.co/npm-dl/eventsource.png)](https://nodei.co/npm/eventsource/)\n\nThis library implements the [EventSource](http://dev.w3.org/html5/eventsource/) client for Node.js. The API aims to be W3C compatible.\n\n## Install\n\n    npm install eventsource\n\n## Usage\n\n```javascript\nvar EventSource = require('eventsource');\n\nvar es = new EventSource('http://googlecodesamples.com/html5/sse/sse.php');\nes.onmessage = function(e) {\n    console.log(e.data);\n};\nes.onerror = function() {\n    console.log('ERROR!');\n};\n```\n\nSee the [spec](http://dev.w3.org/html5/eventsource/) for API docs.\n\n## Example\n\nSee https://github.com/einaros/sse-example\n\n## Extensions to the W3C API\n\n### Setting HTTP request headers\n\nYou can define custom HTTP headers for the initial HTTP request. This can be useful for e.g. sending cookies\nor to specify an initial `Last-Event-ID` value.\n\nHTTP headers are defined by assigning a `headers` attribute to the optional `eventSourceInitDict` argument:\n\n```javascript\nvar eventSourceInitDict = {headers: {'Cookie': 'test=test'}};\nvar es = new EventSource(url, eventSourceInitDict);\n```\n\n### Allow unauthorized HTTPS requests\n\nBy default, https requests that cannot be authorized will cause connection to fail and an exception\nto be emitted. You can override this behaviour:\n\n```\nvar eventSourceInitDict = {rejectUnauthorized: false};\nvar es = new EventSource(url, eventSourceInitDict);\n```\n\nNote that for Node.js < v0.10.x this option has no effect - unauthorized HTTPS requests are *always* allowed.\n\n",
  "readmeFilename": "README.md",
  "_id": "eventsource@0.0.10",
  "_from": "eventsource@0.0.10"
}
