I am using React Native 0.79.6 with Expo 53.0.0 managed development and added Swipe left and Swipe right using from react-native-swipe-gestures 1.0.5 to my main working screen’s . Everything worked fine on Android. But in iOS, the scrolling with one finger sometimes works and sometimes doesn’t. Two finger scrolling always work in iOS. This is not a viable solution because it is an unacceptable user experience to dump on my customer base which has been using my app for two years.
I implemented what I thought was important from my main working screen in a snack – but the snack works fine on my iOS ipad. You can check it out and you will see the basic layout – although all the data is obtained from the cloud and it plays an audio transcript using react-native-track-player which I cannot do in a snack – so I am not sure the snack will help you help me. I
implemented it to demonstrate the problem but failed.
Here it is:
Snack that works
The basic component layout is
- Three buttons (Play/Pause icon only; Next Screen and Previous Screen) and a progress bar
- Title
- Subtitle (extra Text in Snack to demonstrate swipe left and right)
Then the part that is giving me trouble
(using @fobos531/react-native-render-html latest)
The snack has some differences
- No track-player and thus no progress bar. I have taken the progress bar out of my app and still have the same problem in iOS
- I am using the main react-native-render-html because snack will not let me use my version. I have taken render-html completely out of my app and still have the same problem.
- My expo go will not let me use expo 53 in my snack so I am using expo 54 in the snack. I have not tested my app with expo 54 so I don’t know if that is why it fixes it. I have not found a way to get the old version of expo go.
The code component I added to handle swiping the scroll list left and right is
nextEngagement(false)}
onSwipeRight={() => previousEngagement()}
style={styles.container}
>
My guess as to what is wrong is that some component is gobbling up the single finger touch sometimes before does.
Can someone tell me how I can find out why sometimes (50% of the time) the single finger scroll does not work when I added the swipe left and swipe right and perhaps what must be gobbling up that event.
Or perhaps tell me a better and more compatible way to add swipe left and right to my scroll list.
Or perhaps some debugging tools that will help tell me what is going on?
In summary:
I added to my and now the one finger scroll doesn’t always work on iOS while the two finger scroll works perfectly.