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

[RFC]: Add an option to not reset the scroll position on navigate #10703

Open
1 task
MartinDawson opened this issue May 30, 2024 · 1 comment
Open
1 task
Labels
p3 Low priority. The Core team will not prioritize this for now topic/web

Comments

@MartinDawson
Copy link

MartinDawson commented May 30, 2024

Summary

See this issue for more detail: petyosi/react-virtuoso#1014 (comment)

This commit did this: https://github.com/redwoodjs/redwood/pull/1817/files#diff-db921824ed181576fb3274c4f842c348ce40bdb27d103d99dfd7357e97e345c9R97

Motivation

When using pagination in infinite scroll, you want to sync it with the urlParams and use that as the source of truth. However I can't use redwoodjs navigate for this because it internally resets the scroll position on every navigiate. There should be an option to disable it.

Detailed proposal

Add an option to navigate() to not have the scroll reset.

Are you interested in working on this?

  • I'm interested in working on this
@Tobbe
Copy link
Member

Tobbe commented May 31, 2024

Thanks for the suggestion @MartinDawson 🙂
Unfortunately this will get a pretty low priority right now unless you want to try to implement it yourself. Have you had a look at the navigate() function to see if you could add the functionality you need?

@Tobbe Tobbe added the p3 Low priority. The Core team will not prioritize this for now label May 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p3 Low priority. The Core team will not prioritize this for now topic/web
Projects
None yet
Development

No branches or pull requests

2 participants