94 words
1 minute
Undefined is not an object (evaluating 'RNGestureHandlerModule.State')
This happens when you install and use React Navigation without Expo. Ever since React Navigation 3 came out it needs react-native-gesture-handler in order to work. This error usually pops up if Gesture Handler isn’t linked properly. Follows these steps to fix it.
- remove node_modules and package-lock.json
- cd to ios and clear your pods and build folder
- cd back to your root project directory
- npm install
- npm install —save react-navigation
- npm install —save react-native-gesture-handler
- react-native link
- install all modules with npm install
- cd back to ios
- pod install
- cd back to root
- npm run ios
After these steps your project should start to build and run properly again.
Undefined is not an object (evaluating 'RNGestureHandlerModule.State')
https://edwardbeazer.com/posts/undefined-is-not-an-object-evaluating-rngesturehandlermodule-state/