The snapToGrid property (boolean) determines whether task boxes snap to grid cells during moving and resizing.
Declaration
DayPilot.Gantt.snapToGridDefault Value
trueNotes
When set to true, task boxes snap to grid cell boundaries during moving and resizing. When set to false, moving and resizing can continue without grid snapping.
Examples
JavaScript
const gantt = new DayPilot.Gantt("dp", {
snapToGrid: false,
// ...
});
gantt.init();Angular
<daypilot-gantt [config]="config"></daypilot-gantt>config: DayPilot.GanttConfig = {
snapToGrid: false,
// ...
};React
<DayPilotGantt
snapToGrid={false}
{/* ... */}
/>Vue
<DayPilotGantt
:snapToGrid="false"
<!-- ... -->
/>See Also
Availability
Availability of this API item in DayPilot editions:
| Product | Lite | Pro |
|---|---|---|
| DayPilot for JavaScript |
DayPilot