Closed valeriakononenko closed 9 months ago
Can you provide snack?
Sorry, can't play the problem as a snack. I tried, tabs are updated correctly, but appeared another bugs. I'll try another dependencies' versions, cause Expo Snack doesn't allow to use the latest ones. I'll keep you posted if I find what's the problem or close the issue.
My app works fine in Expo Snack.
Expo Snack uses
"expo": "~49.0.18"
with this version dynamic tab labels work fine - labels change when context is changed, tab view is shown
I used
"expo": "^50.0.4"
labels change, but current tab view is blank, tab view updates only when you swipe tabs forward-backward.
I need to update tab label on the fly.
Code works fine until labels changed, after that blank view appears.
Example:
I guess, a blank screen appears because you use label as a key.
Additionally, now label can only be a string. What about React Element? I don't want to rerender the whole screen, but only elements, where label is rendered.
Proposing code: