[v4] | gesture-handler old API Warning and bottomsheet doesn't render
See original GitHub issueBug
When adding a simple bottomsheet to my recently created app I’m greeted with a “using wrong gesture handler api” warning and the bottomsheet doesn’t render.
Full warning message:
[react-native-gesture-handler] Seems like you're using an old API with gesture components, check out new Gestures system!
This doesn’t make sense as I’m following the documentation for both gesture-handler and react-native-bottomsheet and i’m using the latests version of both
Environment info
Library | Version |
---|---|
@gorhom/bottom-sheet | 4 |
react-native | 17.0.2 |
react-native-reanimated | ^2.3.1 |
react-native-gesture-handler | ^2.2.0 |
Steps To Reproduce
1.Simply add and import everything in the “usage” documentation page:
<BottomSheet
ref={bottomSheetRef}
index={1}
snapPoints={snapPoints}
onChange={handleSheetChanges}>
<View style={{ height: 200, backgroundColor: 'red', flex: 1 }}>
<Text>Awesome 🎉</Text>
</View>
</BottomSheet>`
Describe what you expected to happen:
- The botom sheet should appear at 50%, and no warning should appear
Reproducible sample code
The code is in this repository and branch: https://github.com/christian-hess-94/keycash_challenge/tree/bottomsheet-bug
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:12
Top Results From Across the Web
Gesture handler not working on BottomSheet - Stack Overflow
In my code managed to get the bottomsheet to show up but upon swiping up it doesn't move. code.js import { View, Text...
Read more >Troubleshooting | React Native Bottom Sheet - GitHub Pages
This section attempts to outline issues that users frequently encounter when first getting accustomed to using React Native Bottom Sheet.
Read more >Building a BottomSheet from scratch in React Native - YouTube
In this tutorial we'll learn how to create from scratch a BottomSheet component by using the reanimated and the react-native- gesture-handler ...
Read more >React native modal bottom sheet examples pdf download ...
React native bottom sheet navigation. ... react js how to prevent previous radio button active react native how to prevent render in react ......
Read more >A React Native Bottom Sheet with Fully Configurable Options
⚠️ You need to install react-native-reanimated v2 & react-native-gesture-handler and follow their installation instructions. Usage. import React, { ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This is not a bug, it’s not even directly related to this library. https://github.com/software-mansion/react-native-gesture-handler/pull/1817
Bottom Sheet was developed and released, while RNGH was at version 1.X. The new major bump introduced a new api but still supports the old API. Its more like a hint or an developer notification. I am sure Mo will migrate to the new API someday but it is not urgent. You can use LogBox to get rid of this warning.
This issue was closed because it has been stalled for 5 days with no activity.