In an app I'm making, I have a button which hides a bunch of items on a list.
If I'm scrolled halfway down a list of twenty items, then suddenly hide all but two of them with a button, the scroller will still be halfway down and no content will be shown.
To fix this, we could have scrolly calculateHeight on digest - but lazily, only if it hasn't calculated it in last 200ms or so.
This won't cover everything, but it will help and stop it from being a big performance hit.
In an app I'm making, I have a button which hides a bunch of items on a list.
If I'm scrolled halfway down a list of twenty items, then suddenly hide all but two of them with a button, the scroller will still be halfway down and no content will be shown.
To fix this, we could have scrolly calculateHeight on digest - but lazily, only if it hasn't calculated it in last 200ms or so.
This won't cover everything, but it will help and stop it from being a big performance hit.
something like this: