r/reactjs • • Sep 26 '26

Cerious-Scroll: Extremely Fast Dynamic Height virtual scrolling without scrollbar drift or blank space

One of the things I haven’t talked about much with Cerious-Scroll is how it behaves during actual scrolling, especially with variable-height content.

From the beginning, the goal was for virtualization to not look like virtualization.

So even with a large variable-height dataset, you can grab the scrollbar and drag it around quickly without getting the usual weirdness:

  • No scrollbar drift
  • No white space during fast scrolling
  • No waiting for rows to render after you get there
  • Accurate variable-height positioning
  • Native scrolling behavior
  • Constant DOM size regardless of dataset size

The variable-height part is probably my favorite. The scrollbar stays where it should, even when the actual row heights are all over the place.

You can also jump directly to an index way down in the dataset without needing to measure everything before it.

I’ve got demos/benchmarks here if anyone wants to mess with it:

ceriousdevtech.github.io/cerious-scroll

Core:
github.com/ceriousdevtech/cerious-scroll

React:
github.com/ceriousdevtech/react-cerious-scroll

I’m curious how it behaves against some real-world ugly datasets, especially ones with wildly different row heights. Try the scroll engine and tell me your thoughts.

3 Upvotes

7 comments sorted by

View all comments

Show parent comment

1

u/SquallLeonE Sep 27 '26

Ah ok. That's a reasonable compromise to achieve O(1) memory usage. Nice!

Android using Firefox is where I'm having finicky scrolling. Works fine on desktop firefox. Seems to be sensitive to where I'm doing the scrolling motion with my finger.

1

u/Suitable_Language_37 Sep 27 '26

plymer968 commented about the scrolling getting stuck if you hold your finger on a mobile device. I was able to replicate the issue and will be working on a fix. Thanks