function $(arg) { return new $.load(arg); } $.load = function () { alert(1)// this… }; $.load.prototype = $.prototype = { constructor: $, method: function (…) { //… } };