Using built-in components to respond to user gestures
React Native ships with multiple components that have built-in gesture responder support. Basically, these components are an abstracted use of the gesture responder system, which you will learn about in the next section. The gesture responder system provides support for handling gestures in React Native, as well as support for negotiating which component should handle the user gesture.
The simplest user interaction is a tap with one finger. With different Touchable
components, a Pressable
component, and a Button
component, React Native provides different options for how to recognize the tap and respond to the user interaction.
Using components to respond to simple taps
The simplest components to record user taps are the React Native Touchable
components.
Working with Touchable components
React Native provides three different Touchable
components on iOS and an extra fourth Touchable
component just for Android: