utilitaire
Version:
Common utils for JavaScript and Typescript development
19 lines • 674 B
JavaScript
;
var DeepAssign_1 = require("./DeepAssign");
var HasDescriptor = (function () {
function HasDescriptor(desc) {
this.desc = desc;
}
HasDescriptor.prototype.updateInPlace = function (updateDescriptor) {
this.desc = Object.assign(this.desc, updateDescriptor);
return this;
};
HasDescriptor.prototype.copy = function (updateDescriptor) {
var newDescriptor = DeepAssign_1.default(this.desc, updateDescriptor);
var constructWith = this.constructor;
return constructWith(newDescriptor);
};
return HasDescriptor;
}());
exports.HasDescriptor = HasDescriptor;
//# sourceMappingURL=HasDesc.js.map