mirror of
https://github.com/zhigang1992/react-navigation.git
synced 2026-04-30 05:15:25 +08:00
feat: add screenListeners prop on navigators similar to screenOptions
This commit is contained in:
@@ -17,7 +17,12 @@ import type {
|
||||
MaterialBottomTabNavigationEventMap,
|
||||
} from '../types';
|
||||
|
||||
type Props = DefaultNavigatorOptions<MaterialBottomTabNavigationOptions> &
|
||||
type Props = DefaultNavigatorOptions<
|
||||
ParamListBase,
|
||||
TabNavigationState<ParamListBase>,
|
||||
MaterialBottomTabNavigationOptions,
|
||||
MaterialBottomTabNavigationEventMap
|
||||
> &
|
||||
TabRouterOptions &
|
||||
MaterialBottomTabNavigationConfig;
|
||||
|
||||
@@ -25,6 +30,7 @@ function MaterialBottomTabNavigator({
|
||||
initialRouteName,
|
||||
backBehavior,
|
||||
children,
|
||||
screenListeners,
|
||||
screenOptions,
|
||||
...rest
|
||||
}: Props) {
|
||||
@@ -43,6 +49,7 @@ function MaterialBottomTabNavigator({
|
||||
initialRouteName,
|
||||
backBehavior,
|
||||
children,
|
||||
screenListeners,
|
||||
screenOptions,
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user