JavaScript CSS
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
test
.gitignore
.travis.yml
Makefile
Readme.md
component.json
index.js
package.json

Readme.md

proxy-events

Proxy events from one emitter to another.

Build Status

Installation

$ npm install proxy-events
$ component install segmentio/proxy-events

Example

var Emitter = require('events').EventEmitter;
var proxy = require('proxy-events');

var app = new Emitter;
var subapp = new Emitter;

proxy(subapp, app);

app.on('foo', console.log);

subapp.emit('foo', 'bar');
// "bar"

API

proxy(one, another, [prefix])

Proxy events from one emitter to another with an optional prefix.

License

MIT