ARTICLE AD BOX
Asked today
Viewed 33 times
I am getting this error while running my React Native (Expo) project on Android:
enter image description here
I am facing an Android bundling error in my React Native (Expo) project.
When running:
npx expo startor building for Android, I get the following error:
Android Bundling failed 12ms index.js (1 module) Error: [BABEL]: Cannot find module 'react-native-worklets/plugin' Require stack: - node_modules/@babel/core/lib/config/files/plugins.js - ...The app fails to bundle and this error appears repeatedly.
Environment
React Native: (your version)
Expo SDK: (your version)
Node.js: (your version)
npm / yarn: (your version)
OS: (Windows/macOS/Linux)
babel.config.js
module.exports = { presets: ['babel-preset-expo'], plugins: [ 'react-native-worklets/plugin' ], };What I have tried
Deleted node_modules
Deleted package-lock.json
Reinstalled dependencies using npm install
Cleared Expo cache using:
npx expo start -cRestarted Metro bundler
Restarted system
The issue still persists.
New contributor
abhinav is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.
1
Just install react-native-worklets package using - npm i react-native-worklets , also make sure your reanimated package is installed and upto date.
Also in babel.config.js do this:
module.exports = { presets: [ ... // don't add it here :) ], plugins: [ ... 'react-native-worklets/plugin', // add in plugins section ], };Also remove node_modules and package-lock.json completely and hit 'npm i' again if issue persists.
Explore related questions
See similar questions with these tags.
