1

I got the issue in my app when setting enableVirtualization to true but i also could reproduce it here in this stackblitz.

As you can see in this screenshot , rows are not showing on the initial display untill i resize the window. enter image description here

I also noticed that 102 rows were loaded in the dom while only 17 rows were supposed to as they're the only ones visible on the initial display before any vertical scroll. Does the enableVirtualization parameter really works or i'm missing something ?

Please help!

Bardelman
  • 2,176
  • 7
  • 43
  • 70

1 Answers1

0

I had the same issue as you.

The issue was that I forgot to inject the VirtualScroll service.

Inside the <GanttComponent> tag, add <Inject services={[VirtualScroll]}/>

In summary: to enable the virtualization feature for the Gantt chart you will need:

  • In GanttComponent, set enableVirtualization to true (or just add the prop without any value, as React understands it as true)
  • In GanttComponent, set a height in px. It's required, according to the documentation and it must be in pixels.
  • In the Inject tag, add the VirtualScroll service