TypeError: Cannot read property 'offset' of undefined
When scrolling really fast, the following error can always be reproduced.

It appears to be the result of a floating point issue. I was able to reproduce this both on my iPhone and Chrome.

Maybe just parseInt(...)?
I've never seen this, and I've fast-scrolled a lot while testing. Could you tell me more about where you're seeing it? (What app/context? What OS and Chrome version? Which react-virtualized version?)
OSX 10.10.5, Chrome 50.0.2661.102 (64-bit)
Rendering inside a Material UI List.
<List style={styles.list}>
<AutoSizer>
{({ height, width }) => (
<VirtualScroll
height={height}
width={width}
rowCount={leaderboardList.length}
rowHeight={56}
rowRenderer={this.renderItem}
scrollToIndex={skip}
overscanRowCount={5}
/>
)}
</AutoSizer>
</List>
I'm using a custom scroll bar which allows me to scroll from 1 to 10,000 in 100 pixels. (By setting the scrollToIndex={skip} where skip is a percentage of leaderboardList.length (ie. 5000).
Related? https://bugs.chromium.org/p/chromium/issues/detail?id=604033
But I also get the issue on Safari 10 on iOS so I don't know.
Can you give me a repo case? Plunker would be nice. Git repo would be acceptable as well.
Considering I've never seen this in a vanilla react-virtualized project, it's hard to debug.
I'll see if I can set it up. I suspect rapidly updating that scrollToIndex property will probably trigger the issue.
The issue was originating from my application, but thank you for your quick response!
Hey no problem. I really appreciate you letting me know and closing the bug. :)
For anyone that comes across this, I found that it was because I was passing a decimal value to the scrollToIndex. Math.round or any other like ceil, or floor fixes this issue.
Im running into this currently. Very rare. Very frustrated.