Napoleon's Penguin Mascot
    Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

    event-sourcepublic

    event-source

    EventSource polyfill as clean NPM module

    Based on EventSource polyfill maintained by Yaffle. See it's repository for more information.

    Installation

    NPM

    In your project path:

    $ npm install event-source
    

    Browser

    You can easily bundle EventSource for browser with modules-webmake

    Usage

    Expose in global scope

    require('event-source/global');

    If native version is already available, above will do nothing (polyfill won't be loaded).

    Load locally

    var EventSource = require('event-source');

    If native version is available it'll be returned instead of polyfill.

    Tests Build Status

    $ npm test
    

    install

    npm i event-source

    Downloadsweekly downloads

    111

    version

    0.1.1

    license

    MIT

    repository

    githubgithub

    last publish

    collaborators

    • avatar