clauderic / react-tiny-virtual-list

A tiny but mighty 3kb list virtualization library, with zero dependencies 💪 Supports variable heights/widths, sticky items, scrolling to index, and more!
https://clauderic.github.io/react-tiny-virtual-list/
MIT License
2.46k stars 166 forks source link

Invalid offset NaN specified #78

Open AryanSingh opened 4 years ago

AryanSingh commented 4 years ago

image

NawarA commented 4 years ago

I'm getting the same error when trying to use scrollToIndex

NawarA commented 4 years ago

@AryanSingh did you resolve the issue? I'm trying hackery to resolve the bug. Even when I define an offset of 0 or 1 it still says its a NaN. Wondering if you found a fix for this

AryanSingh commented 4 years ago

Sorry man, i left this

On Tue, Mar 17, 2020, 1:18 AM Nawar Alsafar notifications@github.com wrote:

@AryanSingh https://github.com/AryanSingh did you resolve the issue? I'm trying hackery to resolve the bug. Even when I define an offset of 0 or 1 it still says its a NaN. Wondering if you found a fix for this

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/clauderic/react-tiny-virtual-list/issues/78#issuecomment-599728399, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADEQUSH3JWLSD6TLB3WMVSLRHZ7BHANCNFSM4IY5IVFQ .

matatablack commented 3 years ago

Hi! Im getting the same error! Any clues? Really need scrollToIndex scrollToOffset works but the only way i have to get the offset in px is pre measuring all nodes in a hidden portal and that kind of hacky stuff :(
Or assuming a fixed element height

Thanks!