Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Scroll correction sometimes gets stuck on estimating row sizes

Aperta
#1,252 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
42/100
Tipo di issue
Bug
Chiarezza
Da chiarire
Stato di attività
Attiva
Stack tecnologico
react, typescript

Direzione di ricerca

Inizia con la cache delle misurazioni e il comportamento di correzione dello scorrimento di @tanstack/react-virtual, quindi riproduci lo scenario indicato delle righe con ritorno a capo confrontandolo con il video allegato. È ancora necessaria una riproduzione utile; il lavoro è completato quando il layout non presenta più tremolii né entra in un ciclo infinito di correzione dello scorrimento quando le righe vengono visualizzate o scompaiono.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Describe the bug

I think this bug is in the same ballpark to #1221:

We have a complex layout that is (for testing purposes) explicitly undersized and causes layout shifts. This sometimes ends up in an infinite loop trying to correct the scroll position and then stays stuck. Internally we've observed this on some of our playwright tests and eventually found a reproduction.

Oddly enough this behavior can be "fixed" by halting the js execution for a frame and then continue, which makes me suspect that the measurement cache or layout measurement is derived from an outdated layout box.

If necessary, I can try to create a specific sandboxed reproduction.

Your minimal, reproducible example

no reproduction as of yet

Steps to reproduce
  1. Have a layout with virtualized lines that sometime wrap lines (and therefore differ from the size in estimateSize)
  2. scroll up/down with the affected rows appearing/disappearing from the virtualized range
Expected behavior

Table layout should not jitter.

How often does this bug happen?

Every time

Screenshots or Videos

https://github.com/user-attachments/assets/25dbf5de-1f12-442e-8d81-582b1cad8f64

Platform
  • OS: MacOS, Windows
  • Browser: Firefox, Chrome
  • @tanstack/react-virtual: 3.13.9 ... 3.14.9
tanstack-virtual version

3.14.9

TypeScript version

v7.0.0

Additional context

No response

Terms & Code of Conduct
  • I agree to follow this project's Code of Conduct
  • I understand that if my bug cannot be reliable reproduced in a debuggable environment, it will probably not be fixed and this issue may even be closed.
Lingua principale
TypeScript
Stelle
7.1k
Fork
466
Merge medio
2g 31m
PR unite (30g)
13

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di TanStack/virtual

Tutte le issue di TanStack/virtual

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.