You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As @benvan points out in #3357, if you want to subclass a standard view, you also need to port over it's defaults as well. Otherwise, in agendaview at least, slotDuration will be null and there will be an infinite loop. Workaround:
It'd be nicer to bake in the options closer to the class. So, in agenda/config.js for example:
AgendaView.defaults={allDaySlot: true,slotDuration: '00:30:00',slotEventOverlap: true// a bad name. confused with overlap/constraint system };fcViews.customView=AgendaView.extendWithDefaults({// or something like thisduration: {days: 1}});
Which would allow for something like this:
fcViews.myCustomView=FC.AgendaView.extendWithOptions({// more defaults});
The text was updated successfully, but these errors were encountered:
I'm closing this issue to signify that it's implemented (since v4-alpha2). I'll comment on this thread again when v4 is officially released, or if there are further API changes with this.
Simply subclassing a view is all that's required. All options directed at the base view will automatically be applied to the subclass views, without requiring any hacks.
As @benvan points out in #3357, if you want to subclass a standard view, you also need to port over it's defaults as well. Otherwise, in agendaview at least,
slotDuration
will be null and there will be an infinite loop. Workaround:It'd be nicer to bake in the options closer to the class. So, in
agenda/config.js
for example:Which would allow for something like this:
The text was updated successfully, but these errors were encountered: