Search code examples
androidfragmentlifecycle

What happens in the lifecycle of a fragment if a different fragment is created


I have a fragmentA and I create a new fragmentB without removing or popping fragmentA. Is fragmentA still active?


Solution

  • Yes it is. Fragments on the same level of the hierarchy just exist in parallel. They don't influence each other.