The onBeforeEventRender event handler fires for each item in events.list during loading, before the Queue component processes it for display.
Declaration
DayPilot.Queue.onBeforeEventRender(args)Parameters
args.data- event data (a shallow copy of the original object)
Notes
Use this handler to adjust the copied data item before it is rendered. This is a good place to set presentation-related fields such as cssClass or html on the object that will be processed for display.
Examples
JavaScript
const dp = new DayPilot.Queue("dp", {
onBeforeEventRender: (args) => {
args.data.cssClass = "test";
args.data.html = args.data.text + ":";
},
// ...
});
dp.init();Angular
<daypilot-queue [config]="config"></daypilot-queue>config: DayPilot.QueueConfig = {
onBeforeEventRender: (args) => {
args.data.cssClass = "test";
args.data.html = args.data.text + ":";
},
// ...
};React
<DayPilotQueue
onBeforeEventRender={onBeforeEventRender}
{/* ... */}
/>const onBeforeEventRender = (args) => {
args.data.cssClass = "test";
args.data.html = args.data.text + ":";
};Vue
<DayPilotQueue
@beforeEventRender="onBeforeEventRender"
<!-- ... -->
/>const onBeforeEventRender = (args) => {
args.data.cssClass = "test";
args.data.html = args.data.text + ":";
};See Also
Availability
Availability of this API item in DayPilot editions:
| Product | Lite | Pro |
|---|---|---|
| DayPilot for JavaScript |
DayPilot