sstephenson/prototype — pull request #65 by fntzr (2012-09-08 10:52:23+00:00)
Title: Add methods

Hi.

I updated the method `addMethod`. Now you can set variables before add module into object.
For example:

//Before
var Module: {
setup: function() {
this.variable = 'some var';
}
};
//and Class
var C = Class.create({
initialize: function() {
this.setup();
}
});
C.addMethods(Module);

//Now:
var Module: {};
var C = Class.create({});
C.addMethods(Module, function() { this.variable = 'some var'; });