Performance Issue: gantt.open() is very slow, even with few children

Hello,

I am experiencing a significant performance issue with the Gantt chart. When I try to expand a task to show its children by calling gantt.open(taskId) which calls the event onItemOpen, the UI freezes for about 3 seconds before the child tasks are displayed. See the attached GIF.

The latency is inside gantt.open() : I placed a breakpoint on the line gantt.open(taskId) and another one right after it. The entire 3-second delay happens within this single function call.

Enregistrement 2025-10-09 104000

Does anyone have an idea what could cause this ?

Thanks.

Hello,

Unfortunately, I was unable to reproduce this issue. Here’s a code snippet where tasks are expanded and collapsed by calling gantt.open(taskId) and gantt.close(taskId): DHTMLX Snippet Tool.

It’s hard to suppose what exactly goes wrong in your case without more details. It may be useful if you send me a simplified code snippet so I can try to reproduce the issue and research for a possible solution. Please make sure that the issue is reproduced there: DHTMLX - Gantt. Initialization.

Then, click on the Save button. After receiving the link, open it in another tab and check that everything is saved, and then send me this link. If not saved, you can copy the code from the snippet and send it in a text file.

Best regards,
Valeria Ivashkevich
DHTMLX Support Engineer

1 Like

Hello Valeria,

Thank you for your reply.

I’ve upgraded my dhtmlxGantt from version 7.0.3 to 9.0.4 (the latest version), and everything is working fine overall.

I don’t think the issue is related to my code. When displaying only tasks, the Gantt chart works smoothly, and it also performs well when the scale is set to monthly or yearly. However, when I switch to the daily scale and display resources, I experience significant latency.

I inspected this using the browser’s performance tab and noticed that the open() functions is taking a lot of time.

But now with new version I don’t have performance issues anymore.
Best regards,

Hello @Zaki_Z,

Thank you for your follow-up. Yes, since v7.0.3, DHTMLX Gantt has received multiple performance optimizations and improvements, especially in core rendering, resource panel handling, and tree expansion.

For example, there were performance improvements for work time calculation when the duration_unit config is set to “hour” or “day”:

Besides, calculations of resource assignment during batchUpdate and autoScheduling, and the resource panel were also improved:

Because of these and other internal optimizations, many operations (like open()) are now much faster in the newer versions.

Best regards,
Valeria Ivashkevich
DHTMLX Support Engineer

1 Like