After calling scrollToLocation method of SectionList, scroll is jumping
See original GitHub issueUPDATE Check this out
I want to implement something like scrollspy on the web with section list.
I’m using scrollToLocation
method.
The problem is when scrolling is finished the scroll is jumping. I think it causes by loading previous rows. I don’t know why this issue happens even when providing getItemLayout
prop.
Here is a basic demo.
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
After calling scrollToLocation method of SectionList, scroll is ...
I'm using scrollToLocation method. The problem is when scrolling is finished the scroll is jumping. I think it causes by loading previous rows....
Read more >SectionList misses scrollTo* methods · Issue #13151 - GitHub
So the scrollToLocation only works after componentDidMount has been applied to item you need to scroll to. I subscribe to the event in...
Read more >ScrollView - React Native
When true, the scroll view bounces when it reaches the end of the content if the content is larger than the scroll view...
Read more >Help with scrollToLocation in a large SectionList : r/reactnative
When they click on a letter it is meant to scroll and bring them to that section. Much like how the native Iphone...
Read more >react native scroll to element - itatonline.org
As previously mentioned, this method ensures that the scroll moves up or down to show whichever element it is called upon. There are...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Please use Stack Overflow for this type of question.
I have some pretty deeply nested “list” components and I’m having the same issue. I noticed once I switch to a basic
View
,Image
, andText
component with no expensive calculations, that jumping does not occur anymore.I’m thinking this issue correlates to having a “complex” repeating list component.