Fragment state restoration and the FragmentStatePagerAdapter
In the process of building an application for Android I encountered an interesting requirement with a non-trivial solution.
I wanted to implement horizontally scrollable 'pages' in such a way that when the user then added a new item, a new page would be added at the start.
The