The onBeforeTimeHeaderDomRemove event handler runs before a Scheduler time header’s custom DOM content is removed. Use it to release application-owned resources associated with that header.
Declaration
DayPilot.Scheduler.onBeforeTimeHeaderDomRemove(args)Parameters
args.control(DayPilot.Scheduler, read-only): the Scheduler instance.args.header.start(DayPilot.Date, read-only): header start.args.header.end(DayPilot.Date, read-only): header end.args.header.level(number, read-only): zero-based header row index.args.element(read-only): the content supplied by onBeforeTimeHeaderDomAdd, or null if no custom content was supplied.
Lifecycle
In Pro, with progressive time header rendering, headers are created as needed and can be removed after leaving the rendering cache. A full update or disposal also removes existing headers. Keep values that must survive removal in application state.
In Pro, floating time headers move the existing custom content. Floating movement alone does not create or remove a component. React and Vue wrappers handle mounting and unmounting; do not create or dispose a separate framework root for this content.
Use the framework component’s normal cleanup hooks for resources it owns. The removal callback is useful for application subscriptions or observers associated with plain DOM content.
See Also
Availability
Availability of this API item in DayPilot editions:
| Product | Lite | Pro |
|---|---|---|
| DayPilot for JavaScript |
DayPilot