The onBeforeHeaderRender event handler lets you customize the column headers of the JavaScript Calendar component.
DayPilot.Calendar.onBeforeHeaderRender(args);
args.column
(DayPilot.Column) - the column object (read-only)
args.header.areas
(array) - an array of active area objects
args.header.backColor
(string) - custom column background color
args.header.children
(array) - child columns (read-only)
args.header.cssClass
(string) - custom CSS class (since version 2022.4.5481)
args.header.html
(string) - column HTML; if set, it will override the default content
args.header.toolTip
(string) - custom column tooltip
args.header.horizontalAlignment
("left" | "center" | "right") - horizontal alignment of the header cell content
args.header.verticalAlignment
("top" | "center" | "bottom") - vertical alignment of the header cell content
onBeforeHeaderRender: (args) => {
args.header.html = args.column.start.toString("M/d/yyyy");
}