How to make a fixed row? #3826
-
Is it possible to make a row sticky, so that it never disappears when you scroll? I'm able to make a fixed column with a package called react-table-sticky, but that only works for columns. I feel like because of virtualization, the row will always be rendered out when scrolling, so applying CSS style to it will not work. I'm using the package with react-window to allow virtualization. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Because React Table is headless, this is definitely more of an implementation opinion/detail, so thanks for asking as a discussion and not an issue :) You could try to use react-virtual. Here is an example: https://react-virtual.tanstack.com/examples/sticky |
Beta Was this translation helpful? Give feedback.
-
Here is my solution for docked columns https://github.com/GlebKodrik/table There in the readme there is a link to the assembly, which you can follow and see whether or not. In this link, the column has a menu “Fix column”, you can poke it and try scroll |
Beta Was this translation helpful? Give feedback.
Because React Table is headless, this is definitely more of an implementation opinion/detail, so thanks for asking as a discussion and not an issue :)
You could try to use react-virtual. Here is an example: https://react-virtual.tanstack.com/examples/sticky