Infinite scrolling in react-aria table component? #4367
-
heya folks, im struggling to figure out exactly how to have my Table component (built entirely with react aria, as per the useTable page, use infinite scrolling. The current docs for the table collection make reference to virtualization and infinite scrolling in the features section but thats where it stops. Ive tried looking at the react-spectrum tables implementation but im afraid i can't make heads or tails of it. is there any codesandbox examples or documentation i don't know about that leverages just the react-aria hooks in the context of table that also uses infinite loading? cheers folks. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Unfortunately we don't have any code sandbox examples or docs for using an external virtualizer implementation with our aria hooks since we haven't tried it ourselves. Theoretically it should work since our table layout code calculates the position of each of the table row/cell node, the table collection has information regarding the row count/column count, and the table state tracks the selected key and thus that information could be used by an arbitrary virtualized grid to figure out which rows are visible. |
Beta Was this translation helpful? Give feedback.
-
You can take a look at how next-ui does it. That’s how I figured how to do pagination/scrolling etc |
Beta Was this translation helpful? Give feedback.
Unfortunately we don't have any code sandbox examples or docs for using an external virtualizer implementation with our aria hooks since we haven't tried it ourselves. Theoretically it should work since our table layout code calculates the position of each of the table row/cell node, the table collection has information regarding the row count/column count, and the table state tracks the selected key and thus that information could be used by an arbitrary virtualized grid to figure out which rows are visible.