is it normal that the currentBackStack.size == 2 i...
# compose-android
a
is it normal that the currentBackStack.size == 2 in the startDestination? How far away can you smell this code?
v
WDYM? Can't you just compare it with
currentBackStack.destination?.route
?
a
@Valentin Gusselnikov i can navigate from the first page to the second page, which are almost the same, and i want to reuse the same destination, and put an if statement inside the composable where they are different. am i better off using different destinations?
v
Ok, I think I understand now. I would probably use two different destinations, or navigate to the same one but with a
popUpTo
. But all of this depends on a business requirements, like do you need an ability to navigate back and etc.