UNPKG

matematicabisao83

Version:

Um exemplo de projeto node com operações matemáticas

23 lines (18 loc) 1.01 kB
//Agregate module: // After the modules are created, you might want to expose a single object with the items that are exported across all // the modules. Exposing a single object makes it easier for your package users to access the features of your package. // This is the entry point module, which is an aggregate of the other modules in your package. var path = require('path'); var fs = require('fs'); var lib = path.join(path.dirname(fs.realpathSync(__filename)), '../lib'); var simple = require(lib + '/matematicaSimples.js'); var advanced = require(lib + '/matematicaAvancada.js'); module.exports = { addition: simple.addition, subtraction: simple.subtraction, multiplication: advanced.multiplication, division: advanced.division, fibonacci: advanced.fibonacci } // This module first references two built-in node.js packages, path and fs // The call_counter.js module is not referenced because the package uses it but does not expose it