| Name | Type | Description |
|---|---|---|
| exports | object | You should put inside this object all things that you want to expose from the library. For example: In this case function |
//library that exports function 'logSomething' and constant 'MAX_AMOUNT'
var privateFunction = function(msg) {
return '['+msg+']';
};
exports.logSomething = function(msg) {
sys.logs.info('*** logged from library: '+privateFunction(msg));
};
exports.MAX_AMOUNT = 50000;