Bradleycorn
11/10/2020, 2:01 PMnavigation-compose
library. But, the examples in the documentation all show the navController
being passed down into the “Screen” Composables, and click handlers setup that call navController.navigate()
. Without having tried it yet myself, this seems not great. Writing a Composable that requires a navController
makes it less testable and less re-usable, no?
Seems like it might be better to let the composables bubble up events and then handle them and do the navigation at the root level of the tree where the navController exists. But that too can get complicated because a “nav event” might need more than just a route to navigate to (for example, you might want to specify if it should pop the back stack, and how far to pop the back-stack, etc).Ian Lake
11/10/2020, 3:41 PMBradleycorn
11/10/2020, 4:52 PM