Skip to content

Commit 748be60

Browse files
committed
Update upgrade guide for bottom tabs
1 parent ba9fa3c commit 748be60

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

versioned_docs/version-8.x/upgrading-from-7.x.md

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,11 @@ When using the `createXScreen` API, the type of params are automatically inferre
155155

156156
Each navigator exports its own helper function, e.g. `createNativeStackScreen` for Native Stack Navigator, `createBottomTabScreen` for Bottom Tab Navigator, `createDrawerScreen` for Drawer Navigator etc.
157157

158-
Note that this is not a breaking change. It's not required to use this API and your existing code will continue to work as before. You can incrementally adopt this API for new screens to get proper types for `route` object in various callbacks such as `options`, `listeners`, etc.
158+
:::note
159+
160+
This is not a breaking change. It's not required to use this API and your existing code will continue to work as before. You can incrementally adopt this API for new screens to get proper types for `route` object in various callbacks such as `options`, `listeners`, etc.
161+
162+
:::
159163

160164
See [Static configuration docs](static-configuration.md#createxscreen) for more details.
161165

@@ -238,9 +242,9 @@ See [Custom navigators](custom-navigators.md) for more details.
238242

239243
#### Native Bottom Tabs are now default
240244

241-
Previously, the Bottom Tab Navigator used a JavaScript-based implementation and a native implementation was available under `@react-navigation/bottom-tabs/unstable`. Native bottom tabs are not used by default on iOS and Android. This allows us to match the new native design such as liquid glass effect on iOS 26.
245+
Previously, the Bottom Tab Navigator used a JavaScript-based implementation and a native implementation was available under `@react-navigation/bottom-tabs/unstable`. The `@react-navigation/bottom-tabs/unstable` entry point has been removed and it has been merged into the main package.
242246

243-
The `@react-navigation/bottom-tabs/unstable` entry point has been removed.
247+
Native bottom tabs are now used by default on iOS and Android. This allows us to match the new native design such as liquid glass effect on iOS 26.
244248

245249
To keep the previous behavior with JavaScript-based tabs, you can pass `implementation: 'custom'` to the navigator:
246250

@@ -275,14 +279,16 @@ As part of this change, some of the options have changed to work with native tab
275279
- `"labeled"` - same as `tabBarShowLabel: true`
276280
- `"unlabeled"` - same as `tabBarShowLabel: false`
277281
- `tabBarLabel` now only accepts a `string`
278-
- `tabBarIcon` now accepts an function that returns an icon object
282+
- `tabBarIcon` now accepts an function that can return an icon object, returning a react element still works with `custom` implementation
279283

280284
The following props have been removed:
281285

282286
- `safeAreaInsets` from the navigator props
283287
- `insets` from the bottom tab bar props
284288
- `layout` from the bottom tab bar props
285289

290+
If you use `insets` and `layout` in your custom tab bar, you can use [`useSafeAreaInsets`](https://appandflow.github.io/react-native-safe-area-context/api/use-safe-area-insets/) and [`useSafeAreaFrame`](https://appandflow.github.io/react-native-safe-area-context/api/use-safe-area-frame/) from [`react-native-safe-area-context`](https://github.com/th3rdwave/react-native-safe-area-context) instead to get the same values.
291+
286292
See the [Bottom Tab Navigator docs](bottom-tab-navigator.md) for all the available options.
287293

288294
#### Bottom Tabs no longer shows header by default

0 commit comments

Comments
 (0)