Join Slack
Powered by
I have 4 tabs in my app. Each time i go from tab A...
# compose
j
Jasmin Fajkic
10/26/2022, 1:25 PM
I have 4 tabs in my app. Each time i go from tab A to B and return to tab A it refetch data . How to prevent it?
r
Rebecca Franks
10/26/2022, 1:49 PM
You can hoist the state(your data) of your tabs to a higher level composable so as to avoid needing to refetch it.
Rebecca Franks
10/26/2022, 1:51 PM
https://developer.android.com/jetpack/compose/state#state-hoisting
this might help with it.
4
Views
Open in Slack
Previous
Next