4 ms·
> we only render elements that are visible. I'm curious how you keep track of visibility? I have a React app that does something similar to this by checking on
by morley 10y ago
> we only render elements that are visible.
I'm curious how you keep track of visibility? I have a React app that does something similar to this by checking on scroll, but I kept getting killed by the browser having to check layout so many times on scroll, even if I throttled the event listener.
- jhgg 10y agoSince our elements have fixed height, we just do some simple maths in JS land to compute what should be visible, rather than measuring stuff using the DOM (which forces layouts).