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

Feature: preload links in viewport #84

Closed
1 of 3 tasks
daun opened this issue Aug 11, 2023 · 0 comments · Fixed by #86
Closed
1 of 3 tasks

Feature: preload links in viewport #84

daun opened this issue Aug 11, 2023 · 0 comments · Fixed by #86
Assignees

Comments

@daun
Copy link
Member

daun commented Aug 11, 2023

Describe the problem

  • Currently, we have to add DOM attributes on elements to preload
  • That doesn't quite fit the claim of the plugin: smart preloading
  • A better heuristic would be preloading visible links

Describe the proposed solution

  • Implement a feature similar to quicklink: preload visible links in the viewport
  • Install an IntersectionObserver on the viewport
  • Preload all links inside the viewport

Alternatives considered

  • Use quicklink directly
    • They include lots of compatibility code we don't need
    • They have lots of options we don't need

How important is this feature to you?

  • Nice to have
  • Would make my life a lot easier
  • I cannot use swup without it
@daun daun mentioned this issue Aug 11, 2023
5 tasks
@daun daun changed the title Feature: Preload links in viewport Feature: preload links in viewport Aug 11, 2023
@daun daun self-assigned this Aug 11, 2023
@daun daun closed this as completed in #86 Aug 13, 2023
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 a pull request may close this issue.

1 participant