As moving from beginner level coding and deeping into Android apps developing, patterns and architecture, to make my code cleaner and better. I met with a question, that I couldn't find a proper answer to.
And the question is: what is the proper way of using MVP pattern and Fragment? Should each layout have his own Activity, that will host Presenter and Fragment(as I heard putting Presenter to the Fragment itself is not the best practice), or it's better to have 1 hosting Activity that will host all Fragments and just replace them when needed, but create additional layer to manage Presenters switching? And things seem to become much harder when it comes to Tablet layouts or Tabs.
Google samples contains an example of using 1 Activity -> 1 Fragment, but I'm not sure if this is the best way, 'cause creating new Activity makes app 'blink'.
In my apps I use multiple Activities, each with multiple Fragments, all implementing the following architecture. The communication between presenters is done by an event bus or local broadcasts. All presenters can be unit-tested with JUnit. Fragments and Activities do not contain any domain logic, just View
manipulating stuff, not even that if using data binding.