addon

Make your app modular.

  • addon

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
addon
110.0.09 years ago9 years agoMinified + gzip package size for addon in KB

Readme

node-addon
Make your app modular

Usage

var addon = require('addon');

var app = {};

addon.call(app, __dirname + '/plugins/*.js');

app.hello();

// console output
hello, anonymous
In plugins/hello.js:
module.exports = function helloPlugin() {
  var app = this;
  app.hello = function (name) {
    console.log('hello, ' + name || 'anonymous');
  };
};