reactable icon indicating copy to clipboard operation
reactable copied to clipboard

Row Group

Open food-data-sci opened this issue 3 years ago • 2 comments

Is there a way to group rows in reactable and create headers, like the rowGroup functionality you can get in DT?

image screenshot from https://rstudio.github.io/DT/extensions.html

I know you can group them and collapse the whole group but the indentation you get after the group doesn't look great with multiple levels of grouping. + I want the 'headers' visible without a need to expand rows.

Perhaps there's a way to get from collapsible groups to a headed table, like the one in the example I pasted?

food-data-sci avatar Jan 05 '21 14:01 food-data-sci

No, this isn't possible today. The reactable(defaultExpanded = TRUE) option could remove the need to expand rows, but there's no way to change the row grouping behavior. However, I've had the same thought about indentation before, and always wished there was a way to create a flatter nested/tree table structure. A feature like that may come in the future, but I can't say when right now.

glin avatar Jan 23 '21 21:01 glin

A "flatter nested/tree table structure" sounds awesome tbh 😄 I think that creating a tree structure in a table is much more powerful than using shinytree, etc.

jsTreeR is a package that kind of have this feature (see the jsTree grid) but nothing close to reactable.

algo-se avatar Mar 04 '21 11:03 algo-se