onResponderGrant called before onResponderTerminate
See original GitHub issueWhen a responder captures the active responder, it seems that onResponderTerminate
is not called until after onResponderGrant
. This seems like the wrong thing to do. Are there reasons for this behavior?
Issue Analytics
- State:
- Created 8 years ago
- Comments:18 (11 by maintainers)
Top Results From Across the Web
Gesture Responder System - React Native
The gesture responder system manages the lifecycle of gestures in your app. A touch can go through several phases as the app determines...
Read more >Interactions // React Native for Web
These callbacks are always bookended by onResponderGrant (before) and either onResponderRelease or onResponderTerminate (after).
Read more >Maintain Touchable Items with a Parent PanResponder in ...
In that case onResponderGrant will be called, then onResponderMove ... on the active PanResponder if it returns true then onResponderTerminate is called.
Read more >Trying to swipe away items in react-native FlatList but not ...
There is a library called https://github.com/gitboss2000/react-native-swipeable-flat-list. i hope it could work better for you, ...
Read more >2.5 Events · react-native training
7.1.1 JS call OC; 7.1.2 OC call JS; 7.1.3 Native View Component. 7.2 Android. 7.2.1 JS call Java ... handleMoveShouldSetResponder} onResponderGrant={this.
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 Free
Top 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
I still don’t know about the original intent of the diff:
Why is this true? And why are we looking at the return value of
onResponderGrant
? If something wants the gesture lock, shouldn’t it always block native gestures? I’d say so.I just closed https://github.com/facebook/react/pull/6218 because it got stale again. If it is still relevant please submit a new PR (e.g. based on that one) and provide instructions to test the new behavior.