On Apr 18, 02014, at 14:44, Kevin Burton <[email protected]> wrote:

> Thank you. I may have caused a misunderstanding. I have about 20 .js files 
> that I would like to combine into a single module. I would like to do one 
> require and have access to the functions detailed in each of the 20 files. 
> Thus a library.


module.exports = {
   submodule: require(‘./submodule’),
   sub2: require(‘./sub2’),
   func3: require(‘./sub3’).func3,
   func3a: require(‘./sub3’).func3a
};

You’ll have to export what you want from the submodules.

Consider breaking out things that aren’t actually related into their own 
packages.



Attachment: signature.asc
Description: Message signed with OpenPGP using GPGMail

Reply via email to