skip to Main Content

I’ve had this problem for a few days now:

When I build my react native project, I get this warning :
[Reanimated] Unknown version of Reanimated Babel plugin.
See https://docs.swmansion.com/react-native-reanimated/docs/guides/troubleshooting#unknown-version-of-reanimated-babel-plugin for more details.
Offending code was: function anonymous(){const{worklet,args}=this.__closure;worklet(...args);}

The consequences are that my animations don’t work anymore.

Platform: iOS and android
react-native-reanimated version : 3.6.1

I tried many things to get rid of this warning:

  • use –clear-cache on metro
  • clear the entire workspace using react-native-clean-auto AND deleting yarn.lock file
  • create a new workspace and clone again my repository
  • remove recently installed libraries that use reanimated
  • check and move reanimated plugin at the end of the plugins array into babel’s config file
  • get back to older git version of my project -> the issue is now in older versions of my project that worked in the past!

Does anyone is getting the same issue?

2

Answers


  1. I changed inside package.json the version to 3.3.0

    "dependencies": {
      ...,
      "react-native-reanimated": "~3.3.0", 
      ...
    }
    

    then i removed the yarn.lock, run yarn install and reinstall the iOS pods with cd ios && pod install

    Login or Signup to reply.
  2. I fixed it with expo start -c, but if you don’t use expo you can try yarn start --reset-cache or npm start -- --reset-cache

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search