Skip to content
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

Problem with the "BottomNavigation.Bar" component example (route.title) #4453

Open
Tarac21 opened this issue Jul 12, 2024 · 3 comments
Open
Labels

Comments

@Tarac21
Copy link

Tarac21 commented Jul 12, 2024

Current behaviour

The title in route.title is displayed in red to indicate that there is an error.

TS2339: Property title does not exist on type NavigationRoute<ParamListBase, string>

Suppress with @ts-ignore | More actions...

title?: string | undefined

react-native-paper

Expected behaviour

No error message is displayed.

How to reproduce?

Redo the example from https://callstack.github.io/react-native-paper/docs/components/BottomNavigation/BottomNavigationBar.

Preview

What have you tried so far?

Using @ts-ignore does not change anything.

Your Environment

software version
IntelliJ IDEA 2024.1.4 (Ultimate Edition)
android 14
react-native 0.74.3
react-native-paper ^5.12.3
node 20.15.0
npm 10.8.2
expo sdk ?
@Tarac21 Tarac21 added the bug label Jul 12, 2024
@gedu
Copy link
Contributor

gedu commented Jul 15, 2024

Hey, can you provider some code? the I just copy and paste the code from Example into a .tsx and is working

@alienzhangyw
Copy link

Hey, can you provider some code? the I just copy and paste the code from Example into a .tsx and is working

Here's the error:
image

VSCode says the type of route is NavigationRoute<ParamListBase, string>, which doesn't have the property of title.

@SectionTN
Copy link
Contributor

same issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants