The eventSortStrictEnabled property (boolean) enforces custom event-sort priority during automatic placement within a Scheduler row.
Available since 2026.3.7044.
Declaration
DayPilot.Scheduler.eventSortStrictEnabled
Default Value
false
Notes
Configure DayPilot.Scheduler.sortDirections and supply matching
sortarrays on DayPilot.Event.data. The configured directions and sort values determine priority; for example, with["asc"],sort: [1]has higher priority thansort: [7].When enabled, automatic placement keeps an event below overlapping events with higher priority. It prevents lower-priority events from filling a gap above an overlapping higher-priority event.
Equal-priority events retain compact placement. Events in disjoint time ranges can reuse lines; this option does not allocate a permanent line to each priority.
Without custom sort directions or values, this priority constraint is inactive.
Explicit event line assignments retain their placement behavior. Containers remain placement units; the first sorted member determines their outer priority. Reversing row lines also reverses the visual priority direction.
Cannot be combined with DayPilot.Scheduler.groupConcurrentEvents.
Examples
JavaScript
This example assumes that the DayPilot library is loaded and a <div id="dp"></div> element is available.
const dp = new DayPilot.Scheduler("dp", {
startDate: "2026-09-01",
days: 1,
scale: "Hour",
eventSortStrictEnabled: true,
sortDirections: ["asc"],
resources: [{id: "R", name: "Resource"}],
events: [
{
id: 1,
text: "Short high priority",
resource: "R",
start: "2026-09-01T09:00:00",
end: "2026-09-01T10:00:00",
sort: [1]
},
{
id: 2,
text: "Long high priority",
resource: "R",
start: "2026-09-01T09:00:00",
end: "2026-09-01T12:00:00",
sort: [1]
},
{
id: 3,
text: "Low priority",
resource: "R",
start: "2026-09-01T11:00:00",
end: "2026-09-01T12:00:00",
sort: [7]
}
]
});
dp.init();
The low-priority event stays below the long high-priority event, even though the top line becomes free at 10:00.
The following framework excerpts show the relevant options. Supply resources and event data as in the JavaScript example.
Angular
<daypilot-scheduler [config]="config"></daypilot-scheduler>
config: DayPilot.SchedulerConfig = {
eventSortStrictEnabled: true,
sortDirections: ["asc"],
};
React
<DayPilotScheduler
eventSortStrictEnabled={true}
sortDirections={["asc"]}
/>
Vue
<DayPilotScheduler
:eventSortStrictEnabled="true"
:sortDirections="['asc']"
/>
See Also
Availability
Availability of this API item in DayPilot editions:
| Product | Lite | Pro |
|---|---|---|
| DayPilot for JavaScript |
DayPilot