[BUG] isItemVisible does not return true for the last item when scrolled all the way to the end
Closed this issue · 2 comments
Describe the bug
If onScroll callback is used and VisibilityContext.isItemVisible is called inside of it, it does not return true for the last item.
If user scrolls a little back afterwards, then it returns true.
To Reproduce
Sorry haven't had time to create a sandbox example.
Expected behavior
When scrolled all the way to the end, VisibilityContext.isItemVisible should return true without having to scroll a little back.
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
- Browser Chrome 90
- OS: Mac os x
Hi, problem is that onScroll
fire when scroll just started, so before visibility of items changed.
Maybe try to use onUpdate
callback instead?
Got it, thanks. The documentation does not mention this. Maybe that can be clarified in the README.md, I am closing this issue.