Suppose we have 3 fragments with toolbars with up button functionality
SplashFragment -> FragmentA -> FragmentB
This is the expected flow of app. On reaching FragmentB when user presses back button he should go to FragmentA and again on pressing back button the app should exit.
How can we achieve this behaviour using navigation component?
I have tried to do this using the app:popUpTo
inside the action
tag, somehow I managed to make it work for hardware back button but the behaviour for up button didn't change.
Need help on this.