Pan gesture
<InteractiveExample
Tap gesture
<InteractiveExample
Long press gesture
<InteractiveExample
Rotation gesture
<InteractiveExample
Pinch gesture
<InteractiveExample
Hover gesture
<InteractiveExample
Fling gesture
<InteractiveExample
Native gesture
A gesture that allows other touch handling components to work within RNGH's gesture system. This streamlines interactions between gestures and the native component, allowing it to form relations with other gestures.
Manual gesture
A plain gesture that has no specific activation criteria nor event data set. Its state has to be controlled manually using a state manager. It will not fail when all the pointers are lifted from the screen.
Force touch gesture
ForceTouch gesture is deprecated and will be removed in the future version of Gesture Handler.
Gesture detector
GestureDetector is the main component of the RNGH2. It is responsible for creating and updating native gesture handlers based on the config of provided gesture. The most significant difference between it and old gesture handlers is that the GestureDetector can recognize more than one gesture at the time thanks to gesture composition. Keep in mind that GestureDetector is not compatible with the Animated API, nor with Reanimated 1.
Gesture
Gesture is the object that allows you to create and compose gestures.
Composed gestures
Composed gestures (Race, Simultaneous, Exclusive) provide a simple way of building relations between gestures. See Gesture Composition for more details.
Gesture composition & interactions
Composing gestures is much simpler in RNGH2, you don't need to create a ref for every gesture that depends on another one. Instead you can use Race, Simultaneous and Exclusive methods provided by the Gesture object.
Gesture state manager
GestureStateManager allows to manually control the state of the gestures. Please note that react-native-reanimated is required to use it, since it allows for synchronously executing methods in worklets.
Touch events
Touch event attributes: