Or is it perfectly fine to increase the value returned as the user scrolls through the views?
In all examples for a PagerAdapter the value returned is the size of some Collection, thus a static value. The API also doesn't specify wether the value returned by getCount()
is expected to remain static.
The question also applies for the getItemCount()
method of RecyclerView.Adapter
for ViewPager2
.