igniteui-angular icon indicating copy to clipboard operation
igniteui-angular copied to clipboard

Use igx-tree-grid instead of igx-grid

Open amrit-moomie opened this issue 7 years ago • 2 comments

Question

With new igx-tree-grid which is separate module and component I realized if I just set the childDataKey to a value that doesn't existing in data object then the grid with render as non-tree structure like a igx-grid. Working example here https://angular-wandvj.stackblitz.io Code: https://stackblitz.com/edit/angular-wandvj

My questions is that as IgxTreeGridComponent extends IgxGridBaseComponent, can I just use the tree grid and set my childDataKey to get the desired tree-grid or regular grid. Is this going be OK moving forward? Any functionality that I will miss in current of future releases?

amrit-moomie avatar Mar 27 '19 14:03 amrit-moomie

@ammritt, The only difference in the functionality between the igx-grid and the igx-tree-grid is that the igx-tree-grid does not support grouping. Technically you could use the IgxTreeGridComponent for non-tree structures, but using the IgxGridComponent would have a bit better performance since the IgxTreeGridComponent has some additional logic for handling the tree structure.

DiyanDimitrov avatar Mar 28 '19 09:03 DiyanDimitrov

@ammritt I'm closing this as answered re open if you have more questions :)

SlavUI avatar Mar 29 '19 07:03 SlavUI