Type errors on React Navigation v7 for createNativeBottomTabNavigator()
Closed this issue · 0 comments
shovel-kun commented
Seems like they changed the API for createNavigatorFactory()
and DefaultNavigatorOptions
Got type error Expected 0 type arguments, but got 4.
for the following block of code:
export default createNavigatorFactory<
TabNavigationState<ParamListBase>,
NativeBottomTabNavigationOptions,
NativeBottomTabNavigationEventMap,
typeof NativeBottomTabNavigator
>(NativeBottomTabNavigator);
As well as type error Generic type 'DefaultNavigatorOptions' requires 6 type argument(s).
for the block of code:
export type NativeBottomTabNavigatorProps = DefaultNavigatorOptions<
ParamListBase,
TabNavigationState<ParamListBase>,
NativeBottomTabNavigationOptions,
NativeBottomTabNavigationEventMap
> &
TabRouterOptions &
NativeBottomTabNavigationConfig;
Tested with @react-navigation/native@7.0.0-rc.21