Skip to content

Commit 115b163

Browse files
feat(docs): backbehaviour props added (#106)
1 parent 3b9e330 commit 115b163

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

docs/docs/docs/guides/usage-with-react-navigation.mdx

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,18 @@ The name of the route to render on first load of the navigator.
4949

5050
Default options to use for the screens in the navigator.
5151

52+
#### `backBehavior`
53+
54+
This controls what happens when `goBack` is called in the navigator. This includes pressing the device's back button or back gesture on Android.
55+
56+
It supports the following values:
57+
58+
- `firstRoute` - return to the first screen defined in the navigator (default)
59+
- `initialRoute` - return to initial screen passed in `initialRouteName` prop, if not passed, defaults to the first screen
60+
- `order` - return to screen defined before the focused screen
61+
- `history` - return to last visited screen in the navigator; if the same screen is visited multiple times, the older entries are dropped from the history
62+
- `none` - do not handle back button
63+
5264
#### `labeled`
5365

5466
Whether to show labels in tabs. Defaults to true.

0 commit comments

Comments
 (0)