Search code examples
angularag-gridag-grid-ng2

Ag-grid to show both loading and no data overlays


I am working with Ag-grid and I found that only one of loading and no data overlays can be shown at a time.

My situation is that at the beginning, I have no data and a loading observable. I subscribe to that observable and manually call the grid api to setup the loading but it was later replaced by no data overlay due to the grid.

Is there a way to have both running (which I can use css for the loading overlay to hide the no data)?


Solution

  • After playing around, I found that adding showLoadingOverlay() to onRowDataChanged event solves the problem