A node.js module of mine got too big, so I split it into several smaller (sub)modules.
I copy & pasted all relevant objects into each of the submodules, which now look like
var SOME_CONSTANT = 10;
function my_func() { etc... };
Now I want to export everything in each submodule, en masse, without having to explicitly say exports.SOME_CONSTANT = SOME_CONSTANT a million times (I find that both ugly and error prone).
What is the best way to achieve this?