InfiniteTableRowInfo can have different object shape depending on the presence or absence of grouping.
You can use dataSourceHasGrouping: boolean as a discriminator to determine the shape of the object, to know if the dataSource had grouping or not. Furthermore, for when the dataSource has grouping, you can use isGroupRow: boolean to discriminate between group rows vs normal rows.
Now rowInfo has the following props:
childrenAvailable - if at least some of the children (for group rows with lazy batching) are available
childrenLoading - if some children are loading
selfLoaded - if the current row has been loaded (useful for bathing, when scrolling to the current row, when it's lazily fetched)
dataSourceHasGrouping
directChildrenCount - The count of the direct children of the current group. Direct children can be either normal rows or groups.
directChildrenLoadedCount
collapsedChildrenCount - The count of all leaf nodes (normal rows) inside the group that are not being visible due to collapsing (either the current row is collapsed or any of its children)
deepRowInfoArray - This array contains all the (uncollapsed, so visible) row infos under this group, at any level of nesting, in the order in which they are visible in the table
groupData - The array of all leaf nodes (normal rows) that are inside this group.
InfiniteTableRowInfo can have different object shape depending on the presence or absence of grouping.
You can use
dataSourceHasGrouping: boolean
as a discriminator to determine the shape of the object, to know if the dataSource had grouping or not. Furthermore, for when the dataSource has grouping, you can useisGroupRow: boolean
to discriminate between group rows vs normal rows.Now rowInfo has the following props: