Replies: 1 comment
-
|
Performance sections of the docs actually suggests to https://virtuoso.dev/#performance It appears that this is therefore expected behavior. Would still appreciate an example in documentation of appending to a large list, e.g. I would expect that |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I am confused what is the correct way to append items when you have very large array.
As an example, I've tried using
useRefto append to the array and then force refresh.https://codesandbox.io/s/react-virtuoso-component-list-re-render-forked-92iwn?file=/src/App.js
This works, however, it is still recalculating
itemContentevery timetotalCount, i.e. I would not expect it to try to re-render elements that are already visible. Therefore, I suspect that I am doing something wrong.We can obviously memoize whatever element
itemContentreturns, but again, I am just not sure if this is the correct approach.Beta Was this translation helpful? Give feedback.
All reactions