Ahmed Shehata
04/25/2022, 10:48 PMIan Lake
04/25/2022, 11:27 PMviewModel()
or hiltViewModel()
are scoped to that destinationAhmed Shehata
04/26/2022, 1:44 AMhiltViewModel()
but I noticed that the onCleared()
of my VM never get called even I navigated to a different destination.Ian Lake
04/26/2022, 1:46 AMonCleared()
gets called when a destination gets popped off the back stack. This is exactly how Navigation with Fragments work as well 🙂Ahmed Shehata
04/26/2022, 2:31 AM