I have a function like:
define(['module', 'controller'], function(module, controller){
(new module).build();
});
inside module.build
I want to get the arguments automatically of the parent like:
module = function(){
this.build = function(args){
// make args the arguments from caller ( define ) fn above
};
};
I know I could do something like:
module.build.apply(this, arguments);
but I was wondering if there was a better way. Any thoughts?