- Sponsor
-
Notifications
You must be signed in to change notification settings - Fork 5.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Typescript definition is wrong #7315
Comments
Who can tell me the reason ? this lib is written by typescript. so the definition is auto generate ? |
I have this problem too. |
Please try the latest version |
@satya164 the latest version don't solve completely. |
There are more props that exist in the source code but not in types. So far I've had problems with Autocompleting on config object of
As you can see, something seems to be very broken with the types on both tab creators. Version: [email protected] const BottomNavigator = createBottomTabNavigator(tabs, {
tabBarComponent: BottomTabComponent
})
|
I am also having this issue in the latest version. Detailed in issue #6308. |
It's still have some problems. the error picture is in issue #6308 (comment) |
The generated Navigator is also not right. const Home = (props: NavigationProps) => {
const { navigation } = props;
return (
<SafeAreaView>
<Navigator navigation={navigation} /> // exist error
</SafeAreaView>
);
};
Home.router = Navigator.router; // exist error
|
typeof createBottomTabNavigator // React.ComponentType<{}>; However, createAppContainer requires a parameter of type
Parameters of type "ComponentType<{}>" cannot be assigned to parameters of type "NavigationNavigator<unknown, unknown>". |
Still having this issue with v5... |
Hey! This issue is closed and isn't watched by the core team. You are welcome to discuss the issue with others in this thread, but if you think this issue is still valid and needs to be tracked, please open a new issue with a repro. |
Current behaviour
'initialRouteName' does not exist in type 'NavigationBottomTabOptions'
Expected behaviour
no error
Your Environment
The text was updated successfully, but these errors were encountered: