Skip to content

Commit 5a5c8e5

Browse files
committed
[fix] Forward scroll end event to ScrollView onScroll handler
Close #1728
1 parent 5a150c0 commit 5a5c8e5

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/react-native-web/src/exports/ScrollView/ScrollViewBase.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,9 @@ const ScrollViewBase = forwardRef<Props, *>((props, forwardedRef) => {
111111
if (scrollTimeout.current != null) {
112112
clearTimeout(scrollTimeout.current);
113113
}
114-
scrollTimeout.current = setTimeout(handleScrollEnd, 100);
114+
scrollTimeout.current = setTimeout(() => {
115+
handleScrollEnd(e);
116+
}, 100);
115117
if (scrollState.current.isScrolling) {
116118
// Scroll last tick may have changed, check if we need to notify
117119
if (shouldEmitScrollEvent(scrollState.current.scrollLastTick, scrollEventThrottle)) {

0 commit comments

Comments
 (0)