Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add restore scroll option to CacheSnapshot getter #422

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

inokawa
Copy link
Owner

@inokawa inokawa commented Mar 28, 2024

fix #415

TODO support scroll from bottom usecase

@mariia-mitiureva
Copy link
Contributor

mariia-mitiureva commented Apr 22, 2024

It would be great to support not only scroll from bottom use case, but also allow to set any initial scroll position. Something like this:

initialScrollOffset?: number;
initialScrollIndex?: number |  ScrollToIndexOpts & { index: number };

@mariia-mitiureva
Copy link
Contributor

Update to my last comment: initialScrollOffset might be hard to implement, if it's not restoring from snapshot case. It probably would need to do some measurements in order to work correctly. So personally for me initial index (with ScrollToIndexOpts support) would be enough :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: Can't reverse scroll without mounting initial off-screen items
2 participants