Here you can find the source of extend(other)
// Copy properties from [other] to [this] object. Object.prototype.extend = function(other) { let property;/* w w w. j a v a 2s . c om*/ for (property in other) { if( other.hasOwnProperty(property) && other[property] != null ) { this[property] = other[property]; } } return this; };
Object.prototype.extend = function(){ var Obj = function(){}; Obj.prototype = this; return new Obj();
Object.extend = function(destination, source) { for (var property in source) { if (source.hasOwnProperty(property)) { destination[property] = source[property]; return destination; };
Object.extend = function(destination, source) { for (var property in source) { if (source.hasOwnProperty(property)) { destination[property] = source[property]; return destination;
Object.prototype.extend = function(obj) { for (var i in obj) { if (obj.hasOwnProperty(i)) { this[i] = obj[i]; }; Array.prototype.first = function() { return this.length && this[0]; ...
Object.prototype.extend = function (object) var combined = this; object.each( function (value, key) combined[key] = value; }); return combined; }; ...
Object.extend = function(target) { Array.toArray(arguments, 1).forEach(function(source) { var fld; for (fld in source) { if (source.hasOwnProperty(fld)) { target[fld] = source[fld]; }); ...