Closed vaasu-dhand-als closed 1 year ago
Your custom Item implementation is incorrect, as you don't pass the necessary data props down to the actual element.
Even with that fixed, however, the scenario does not work. I can see errors regarding the measurement of the items resolving to zero, which is incorrect. Not sure if resize observing works with SVG at all.
I have no capacity to investigate this scenario further, it's also a fairly niche one. Happy to accept a reasonable PR if you're willing to dig down and figure out what's going on.
Describe the bug I am trying to create a vertical svg strip with the rect elements virtualized based on the parent component's scroll position. I spent quite a lot of time implementing a solution, but could not come up with one. I have noticed the following issues while working with svg elements:
totalCount
is clearly greater than 1.Reproduction Codesandbox
To Reproduce Steps to reproduce the behavior:
rect
element being rendered inside thesvg
tagExpected behavior Expected behaviour is to see the correct number of
rect
elements and the virtualization to work.Screenshots
Desktop (please complete the following information):
Additional context