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.

Animated gesture must be callback worklet

See original GitHub issue
Gesture.Tap().onStart(() => console.log('tapped'))

react-native: 0.66.4 react-native-gesture-handler: 2.1.0 react-native-reanimated: 2.3.0

Issue Analytics

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

github_iconTop GitHub Comments

6reactions
wcandilloncommented, Jan 11, 2022

I’ve been experiencing this error message with expo 44. Everything was working fine but as soon as I started to use Pinch() with onEnd(), I needed to mark all callbacks as “worklet”. Could it be because of the code formatting the babel plugin is not able anymore to whitelist the callbacks?

0reactions
WoLewickicommented, Mar 31, 2022

Since there is already an issue for what @wcandillon reported: https://github.com/software-mansion/react-native-gesture-handler/issues/1821, I will close this issue then. Feel free to comment if I am wrong and we can always reopen it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

useAnimatedGestureHandler | React Native Reanimated
This hook allows for defining worklet handlers that can serve in a process of handling gestures. Before you can use the hook, make...
Read more >
How to use setState in worklet · Issue #1155 - GitHub
Description how to change state or same in reanimated v2 events Code const x = useSharedValue(0); const [state , setState] = React.
Read more >
Error in Reanimated "tried to synchronously call function res ...
Have tried defining the onEnd as a 'worklet' and using the runOnJs function suggested to solve this but I am not sure I...
Read more >
Events | React Native Reanimated
PanGestureHandler not only reports down and up events (that we subscribed to with onStart and onEnd worklets), but also allows us to track...
Read more >
A First Look at Reanimated 2 — Mobile - Shopify Engineering
Reanimated 2 is based on a new API named animation worklets. ... When writing gestures and animations, you need to do three things:....
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