-
Hi, I have a very simple Virtuoso list with a Header on top of it. Inside this header I have a component with state. I noticed that when the list re-renders, this state is lost. I think that is because the component inside is being unmounted and mounted again, even thought the items and header are still visible (and hence mounted). So my question is, if it is possible to preserve the state of a component inside a Virtuoso list? (items or header) Thanks! L. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I managed to solve my problem by using context to pass the state I need to the components I'm rendering. |
Beta Was this translation helpful? Give feedback.
I managed to solve my problem by using context to pass the state I need to the components I'm rendering.