software-mansion/react-freeze

Freezing with react navigation bottom-tabs

tedi opened this issue ยท 4 comments

tedi commented

Thank you for your work with this library, very excited to put it in production.

While testing things out almost everything seemed to work smoothly, with the exception of react navigation bottom-tabs. We noticed this specifically on screens with media playing. We have a state update that fires on navigation blur. The media then adjusts play state when that happens. This works as expected when navigating within the same tab.

However when switching tabs, we ran into some issues. The state does not update on time, causing the media to be frozen in a playing state when navigating to a different tab. The blur event seems to fire appropriately, so my guess is that the previous tab is freezing almost immediately, not allowing side effects.

Currently running the latest version of all react-navigation libraries and RN 0.64.1

Would love any feedback on dealing with this scenario.

Thanks,
Tedi

@tedi could you provide a repo or a code snippet with minimal configuration needed to reproduce the issue?

tedi commented

@WoLewicki will do in the next few days. Thanks.

@tedi ๐Ÿ“

I'm closing this issue because it looks like this problem was explained in detail in software-mansion/react-native-screens#1198,

fixed in software-mansion/react-native-screens#1220,

and released in react-native-screens v3.10.0 ๐ŸŽ‰