react-native-reanimated: Reanimated 2 failed to create a worklet
When I import Animated in my file, no matter I use it somewhere or not, every time it says that Reanimated 2 failed to create a worklet, maybe you forgot to add Reanimated's babel plugin?.
My babel.config.js
module.exports = {
presets: ['module:metro-react-native-babel-preset'],
plugins: ['react-native-reanimated/plugin'],
};
I’m using ^2.0.0-rc.3 version.
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Reactions: 4
- Comments: 28 (4 by maintainers)
yarn start --reset-cachehelped in my case on Android.npx react-native start --reset-cachesolved my issueSame situation here:
The same is happening to me 😦
I also can confirm it does work, so I’m going to close this issue.
It’s solved now, I ran the app on the real device, it had no problem and then everything was ok in the simulator
Same issue, fresh new react native project
Also seeing this in a fresh react-native app (using react-native-reanimated 2.0.0-rc.3)
None of these solutions has worked for me, and I’m surprised the bug is closed because “use yarn instead of npm” doesn’t feel like a solution. (Even if it did work, which it didn’t for me.)
For anyone else in this situation, reverting to the last stable as @valfirst did ^^ seems to be the only surefire fix.
In package.json:
@jakub-gonet fyi in case this ongoing thread is muted for you
Still an issue for me on a fresh
npx react-native initproject, have only used yarn to install dependencies, tried cleaning yarn cache. Both on a real ios device and simulator.@hitanshuGajjar20 Great, thanks, will keep it in mind. Btw, I switched to
yarna couple of days agoThis is also not helping me
I am also getting the same issue even after following all the instruction i have also tried to reset cache
can anyone help me Please