undefined is not an object (evaluating 'RNGestureHandlerModule.State'

前端 未结 20 774
Happy的楠姐
Happy的楠姐 2020-12-01 04:43

I have installed react-navigation in my React Native project. Its a starter project doesn\'t have any codes. But while running project I am facing

相关标签:
20条回答
  • 2020-12-01 05:12

    If you are using a configuration with Podfile in ios. Follow this steps:

    • Comment this line pod 'RNGestureHandler', :path => '../node_modules/react-native-gesture-handler' in <react-native-project>/ios/Podfile.
    • Open <react-native-project>.xcworkspace Add RNGestureHandler.xcodeproj in Libraries (Right click over library folder and select "Add files to ") from node_modules/react-native-gesture-handler/ios.
    • Add libRNGestureHandler.a in (Build Phases) -> (Link Binary With Libraries).
    0 讨论(0)
  • 2020-12-01 05:12

    This worked well for me as well.
    1) npm install react-navigation
    2) npm install react-native-gesture-handler
    3) npm intstall
    4) react-native link

    uninstall the app

    5) react-native run-android

    0 讨论(0)
提交回复
热议问题