function $(node) {
return new $.wrapper(node);
}
$.wrapper = function (node) {
this.node = node;
};
$.wrapper.prototype = $.prototype = {
constructor: $,
load: function () {
alert(1);
},
test: function () {
alert(this.node.nodeName);
return this;
}
};
$(document.body).test().load();