Coordinator-MVVM-Rx-Example icon indicating copy to clipboard operation
Coordinator-MVVM-Rx-Example copied to clipboard

Finishing an entire flow

Open chrsp opened this issue 3 years ago • 0 comments

Hi. I'm using this Coordinators idea in my projects and have a issue here regarding to memory management. Imagine that I started a specific flow: the Login flow. This flow has 3 screens, and after the login is completed I go to the home screen. When I'm in the home screen I want to free all the Login flow screens from the memory. How to do that? One thing I tried to do was to go in the first Login screen coordinator and emitting an onNext event, so it should be disposed. However, it isn't being disposed. Another problem is: for this cases I have to not only all be concerned about releasing the coordinator, but to removing the controllers from the navigationController. I think the best way to do that was to be able to, in this case, when I'm starting a new flow, like the home flow, I should be able to simply starting it from the strath ignoring the previous one, that should be automatically released. Some way I can do that in the current structure?

chrsp avatar Dec 07 '20 15:12 chrsp