question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can't disable PanGestureHandler

See original GitHub issue

I disable a PanGestureHandler through its enabled prop while it’s responding, I disable it using setState when a value hits a limit while the interaction is going on. Handler stops responding as expected. However, after that when I start interacting again, even though enabled={false} it keeps responding. (On iOS, haven’t tested on Android)

(Also not related but a question: This PanGestureHandler is inside a ScrollView, after I disable the PanGestureHandler, I want ScrollView to respond as normal in that same continuous finger move, how can I do this? Any ideas?)

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

3reactions
osdnkcommented, Jul 16, 2018

Hi, I did wish to repro it so I’ve added enabled={false} (and handled it with state then) to draggable example and it works as I expected. Would you mind providing some code?

0reactions
osdnkcommented, Aug 21, 2018

For now I decided to close this issue as it is related to another one

Read more comments on GitHub >

github_iconTop Results From Across the Web

how to disable RectButton from react-native-gesture-handler
On react-native buttons ie touchableOpacity you have the disabled prop but it doesn't appear to work on RectButton
Read more >
Introduction | React Native Gesture Handler - Software Mansion
Gesture Handler aims to replace React Native's built in touch system called Gesture Responder System.
Read more >
PanResponder - React Native
By default, PanResponder holds an InteractionManager handle to block long-running JS events from interrupting active gestures.
Read more >
React Native Gesture Handler and Reanimated Tutorial
Your browser can't play this video. Learn more. Switch camera.
Read more >
Gmail Swipe Using React Native PangestureHandler - YouTube
PangestureHandler animations are cool with reanimated from react native reanimated. ... Your browser can't play this video.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found