Hello folks, I was reading the following code from the documentation (link):
And my question is if inside a composable i want to be aware of bottomBarTabs changes, it should be observed as state? or should I use another mechanism?
Lisandro Di Meo
07/28/2022, 4:19 PM
Copy code
class MyAppState(
val scaffoldState: ScaffoldState, ....
) { val bottomBarTabs = /* State */ /*other stuff*/}
@Composable
fun rememberMyAppState(
scaffoldState: ScaffoldState = rememberScaffoldState(),
/* ... */
) = remember(scaffoldState, navController, resources, /* ... */) {
MyAppState(scaffoldState, navController, resources, /* ... */)
}