You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+15-9Lines changed: 15 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,29 +1,31 @@
1
-
# @th3rdwave/react-navigation-bottom-sheet
1
+
# @appandflow/react-navigation-bottom-sheet
2
2
3
3
Bottom sheet navigator for React Navigation.
4
4
5
+
Can also work with Expo Router [example](./example/expo-router/)
6
+
5
7
Integrates [@gorhom/bottom-sheet](https://github.com/gorhom/react-native-bottom-sheet) with [React Navigation](https://github.com/react-navigation/react-navigation).
If you don't have those already, you will also need to install the [@gorhom/bottom-sheet dependencies](https://gorhom.github.io/react-native-bottom-sheet/#dependencies) react-native-reanimated and react-native-gesture-handler.
// Can pass any prop from @gorhom/bottom-sheet's BottomSheetModal
35
-
options={{ snapPoints: [200, "100%"], index:1 }}
37
+
options={{ snapPoints: [200, '100%'], index:1 }}
36
38
/>
37
39
</BottomSheet.Navigator>;
38
40
39
41
// ...
40
42
41
43
// Open like any regular react-navigation screen.
42
-
navigation.navigate("firstSheet", { id:1 });
43
-
44
+
navigation.navigate('firstSheet', { id:1 });
44
45
```
45
46
46
-
See the [example app](./example/src/SimpleExample.tsx) for full usage details.
47
+
See the React Navigation [example app](./example/react-navigation/src/SimpleExample.tsx) or the Expo Router example under [`example/expo-router/app`](./example/expo-router/app) for full usage details.
48
+
49
+
### Running the examples
50
+
51
+
-`yarn example:react-navigation` – launches the classic React Navigation sample
52
+
-`yarn example:expo-router` – launches the Expo Router sample
47
53
48
54
## API
49
55
@@ -52,7 +58,7 @@ See the [example app](./example/src/SimpleExample.tsx) for full usage details.
52
58
#### `snapPoints`
53
59
54
60
```ts
55
-
Array<string|number>
61
+
Array<string|number>;
56
62
```
57
63
58
64
Points for the bottom sheet to snap to, points should be sorted from bottom to top. It accepts array of number and string.
0 commit comments