Gantt chart click listener event issue or bug
When used in reactjs gantt chart add button fires multiple time when component updates or router changes, I have only one instance of gantt but it fires multiple time anywhere, older version of gantt chart doesn't do that
Hi, it probably has to do with event handlers being attached on componentDidMount and never detached. So after a component has been mounted for the second time your handlers will be duplicated.
As a solution, you'll need to set some flag and attach event handlers only once as shown here https://dhtmlx.com/blog/create-react-gantt-chart-component-dhtmlxgantt/#comment-196907 I'll try to update the react demo repo and an article in the nearest time
Starting from dhtmlxgantt v5.1 a gantt instance will have a destructor method, so you'll be able to create a new instance of gantt in componentDidMount and destroy it in componentWillUnmount and not have such issue.