add/remove components of a scroller without changing the position?

I'm working on a bible reading mobile app in which the main screen is a scroller. given the version of bible I'm using is 4.8MB (possibly 500k+ all kinds of html nodes), consists of 1k+ chapters, It's practically not possible to load all the text so I plan to load chapter by chapter. It's relatively easy to determine when to add and remove chapters by listen to onScroll/onScrollStop events. But the problem is when add/remove chapters, the scroll position also changes. Is there a way to do it without the unintended effects? Would it be simpler and less memory intensive if I just remove text of those out of screen and assign the height of the chapter container as if text still there? thanks!

Comments

Sign In or Register to comment.