Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

updating preventSwipe won't work #121

Open
shubhurwt2001 opened this issue Oct 21, 2022 · 2 comments
Open

updating preventSwipe won't work #121

shubhurwt2001 opened this issue Oct 21, 2022 · 2 comments

Comments

@shubhurwt2001
Copy link

shubhurwt2001 commented Oct 21, 2022

preventSwipe with initial render works fine, but after updating the state with a new prevent direction does not work. How to achieve it?

@LinusU
Copy link
Collaborator

LinusU commented Oct 26, 2022

I think that this is because the pan handler doesn't get recreated because no dependencies here:

So it refers to an old handleSwipeReleased here:

handleSwipeReleased(setSpringTarget, gestureState)

@3DJakob
Copy link
Owner

3DJakob commented Nov 8, 2022

I am aware of this issue and it is on the TODO list I will fix it as soon as I have time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants