The markers fail to re-render when I navigate away from the page and return

I’m having an issue with the downtime marker. I can’t switch pages in the platform because whenever I do, all the markers disappear. Even if I reload the Gantt or trigger the downtime function again, they still don’t show up. In the HTML, the marker element simply vanishes.

How can I ensure that the markers remain visible when I return to the Gantt?

Hello @Daniel_Souza,

When you switch between pages, the markers can disappear if the Gantt instance (or its container) is destroyed and then recreated. The same happens if you use gantt.clearAll(), since this method removes markers as well. Because markers are not part of the task dataset, they do not restore automatically after re-initialization.

To keep markers visible, you need to add them again each time the Gantt is initialized.

Here’s an example of how you can re-add markers after creating a new Gantt instance: DHTMLX Snippet Tool.

Best regards,
Valeria Ivashkevich
DHTMLX Support Engineer