本文整理匯總了TypeScript中jQuery.extend函數的典型用法代碼示例。如果您正苦於以下問題:TypeScript extend函數的具體用法?TypeScript extend怎麽用?TypeScript extend使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了extend函數的9個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: function
[add.hide]: function (state, action) {
return $.extend({}, state, action.data, {
visible: false,
hasError:false,
url:''
});
}
示例2:
[add.error]:function(state,action) {
return $.extend({},state,{
hasError:true,
isLoading:false,
errorMessage:action.errorMessage
});
},
示例3: constructor
constructor(_calendar, overrides) {
super()
this._calendar = _calendar
this.overrides = $.extend({}, overrides) // make a copy
this.dynamicOverrides = {}
this.compute()
}
示例4: getSaveModelClone
// cleans meta data and other non peristent state
getSaveModelClone() {
// temp remove stuff
var events = this.events;
var meta = this.meta;
var rows = this.rows;
var variables = this.templating.list;
delete this.events;
delete this.meta;
// prepare save model
this.rows = _.map(rows, row => row.getSaveModel());
this.templating.list = _.map(variables, variable => variable.getSaveModel ? variable.getSaveModel() : variable);
// make clone
var copy = $.extend(true, {}, this);
// sort clone
copy = sortByKeys(copy);
// restore properties
this.events = events;
this.meta = meta;
this.rows = rows;
this.templating.list = variables;
return copy;
}
示例5: function
[player.remove]: function (state, action) {
return $.extend({}, state, {
playlist: state.playlist.filter(data => {
return data.id != action.id;
})
});
},
示例6: setGutters
/*
If falsy, resets all the gutters to 0
*/
setGutters(gutters) {
if (!gutters) {
this.gutters = {}
} else {
$.extend(this.gutters, gutters)
}
this.updateSize()
}
示例7:
[session.success]:function(state,action) {
sessionStorage['username2']=action.data.user.username;
sessionStorage['studioid2']=action.data.user.studioId;
return $.extend({},state,action.data,{
hasError:false,
isLoading:false
});
},
示例8: queryScroll
queryScroll() {
const scroll = View.prototype.queryScroll.apply(this, arguments)
if (this.isResourcesRendered) {
$.extend(scroll, this.queryResourceScroll())
}
return scroll
}
示例9: function
EventDef.prototype.applyMiscProps = function(rawProps) {
rawProps = $.extend({}, rawProps) // clone, because of delete
this.resourceIds = Resource.extractIds(rawProps, this.source.calendar)
delete rawProps.resourceId
delete rawProps.resourceIds
origMethods.applyMiscProps.apply(this, arguments)
}