[Bug] [v2] Autoscroll to bottom doesn't work when items are changing its size
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 7.2k
- Forks
- 393
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 1
Description
Current behavior
I have a chat interface and I want it to open on the latest message. To achieve that I'm using maintainVisibleContentPosition with the following config:
maintainVisibleContentPosition={{
startRenderingFromBottom: true,
autoscrollToBottomThreshold: 0.2,
}}
However, when items are changing their size, autoscroll to the bottom doesn't work.
https://github.com/user-attachments/assets/a7a0dad7-f840-42cc-89b6-6afb6a0301b1
Expected behavior
The list should keep the scroll position at the bottom, even when the size of item changes.
To Reproduce
https://github.com/jmysliv/rn-playground/tree/%40jmysliv/flash-list
Platform:
- iOS
- Android
Environment
2.0.0-alpha.11
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the fixture app at https://github.com/jmysliv/rn-playground/tree/@jmysliv/flash-list and reproduce the iOS issue using maintainVisibleContentPosition with startRenderingFromBottom and autoscrollToBottomThreshold. Trace how changing item sizes affect autoscrolling, then verify that the list remains at the bottom while item dimensions change.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react-native, typescript
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100