question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Bug] List with CellMeasurer not scrolling properly

See original GitHub issue

Description: When rendering a List with CellMeassure and scrollToIndex is set on the last index of the list. It gets “freezed” at that position, so it can’t be scrolled up.

Reproducible here: Plunker

Affected version: v9.12.0

Issue Analytics

  • State:open
  • Created 6 years ago
  • Reactions:3
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
rickhanloniicommented, Nov 27, 2017

I got a little further on this and I think I understand the problem

What’s happening is that the CellMeasurer is coming to new cells and calling Grid.invalidateCellSizeAfterRender. That’s eventually getting to this line:

this._recomputeScrollTopFlag = scrollToRow >= 0 && rowIndex <= scrollToRow;

Which will reset the scrollTop on the next cDU only when scrolling up. If you reverse the <= to >= then the same problem happens when scrolling down

0reactions
DavidCarycommented, Sep 19, 2019

I should have written that this appears to have been partially fixed as of version 9.20.1. Can anyone share an example where the problem still exists in the current version?

Read more comments on GitHub >

github_iconTop Results From Across the Web

react-virtualized: scrollToIndex not working with CellMeasurer
I'm having an issue with CellMeasurer in conjunction with scrollToIndex on a List . If I set scrollToIndex to some large value (presumably ......
Read more >
bvaughn/react-virtualized - Gitter
Hello guys thanks for the awesome work, i am using virtualized list with autosizer and window scroller, the only issue i am facing...
Read more >
Rendering large lists with React Virtualized - LogRocket Blog
But what if you need to show thousands of rows at the same time? And what if techniques like pagination or infinite scrolling...
Read more >
react-virtualized | Yarn - Package Manager
React components for efficiently rendering large, scrollable lists and tabular data. react, reactjs, react-component, virtual ...
Read more >
574283 - smooth scrolling for mouse wheel on Mac - chromium
Can you please provide an update on the status of this bug? Priority 2 PM-Followup bugs should be updated at least every 6...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found