Skip to content

Commit

Permalink
enabling both browser and node support (fixes #4)
Browse files Browse the repository at this point in the history
  • Loading branch information
dominicbarnes committed May 17, 2015
1 parent 1822a5b commit 46308ed
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
1 change: 1 addition & 0 deletions component.json
Expand Up @@ -3,6 +3,7 @@
"description": "Application-wide event bus",
"version": "0.0.3",
"dependencies": {
"camshaft/require-component": "*",
"component/emitter": "*"
},
"scripts": [
Expand Down
8 changes: 7 additions & 1 deletion index.js
@@ -1,4 +1,10 @@

/**
* Wrapper for require to enable simultaneous node/component use.
*/

require = require('require-component')(require);

/**
* Module dependencies.
*/
Expand All @@ -9,4 +15,4 @@ var Emitter = require('emitter');
* Expose the event bus.
*/

module.exports = new Emitter;
module.exports = new Emitter;
3 changes: 2 additions & 1 deletion package.json
Expand Up @@ -3,7 +3,8 @@
"description": "Application-wide event bus",
"version": "0.0.3",
"dependencies": {
"component-emitter": "*"
"component-emitter": "*",
"require-component": "*"
},
"component": {
"scripts": {
Expand Down

0 comments on commit 46308ed

Please sign in to comment.