Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add new item error when use VariableSizeList #762

Open
2239559319 opened this issue Apr 2, 2024 · 1 comment
Open

add new item error when use VariableSizeList #762

2239559319 opened this issue Apr 2, 2024 · 1 comment

Comments

@2239559319
Copy link

How to reproduce?

Go to this codesandbox, click add

What is the expectation?

The list increases after clicking add button, list should be 0 to 5

What actually happened?

0 1 and 2 item lost

@ches4117
Copy link

ches4117 commented Jul 9, 2024

Your numbers disappear because you use ref?.current?.scrollTo((newData.length - 1) * 37);,
You could try to use ref?.current?.scrollTo(0);, or shorten the List height like height={100}, it will be scrollable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants