I have a bunch of "modules" which follow the "JavaScript Module Pattern" as described in this popular article. To my understanding these modules are a way to aggregate various bits of behavior into neat namespaces.
But what if I want to be able to create a unique object instance which accepts arguments? As it stands, I can't do that as all the data is shared/static. I want to be able to do this:
var foo = new Some.Namespace.Whatever.Foo(config);
I can't change the structure of the pattern as we've been using it for a while and it works very well. I just want to tweak it so I can throw some "classes" into it which work with non-static data.
new.