Open ajrulez opened 7 years ago
Hi @ajrulez ,
Yes, the point of the library is to avoid recreating Fragments and to keep the view states of each fragments.
From what I've tested the fragments are only recreated when the Activity is rotated. This is unavoidable from what I've tested so far. However if you have an improvement or an idea to solve this, please send a PR.
Cheers, Viven.
Thanks for the comment.
I was testing the sample app, and I had put breakpoints in on onCreateView, onViewCreated (and all other Fragment lifecycle methods). Much to my disappointment, all Fragments were being created every time I navigated between different Fragments using BottomNav.
I thought the very point of this library is to avoid re-creating Fragments, please correct me if I am wrong. I would appreciate any help with this (ajrulez@gmail.com)
Is it because - Fragment fragment = mFragmentManager.findFragmentByTag(tag); always returns null in method "changeFragment()". ??