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

[intersect] enhance with more events & scroll direction detection #96

Open
2 tasks
vnphanquang opened this issue Jan 11, 2023 · 0 comments
Open
2 tasks
Assignees
Milestone

Comments

@vnphanquang
Copy link
Owner

vnphanquang commented Jan 11, 2023

Context

It's more convenient to have an on:intersectleave & on:intersectenter events, especially in use cases to track if element is in view.

Also it's helpful sometimes to know the scrolling direction.

Inspiration might be pooled from https://github.com/maciekgrzybek/svelte-inview/blob/master/src/inview.ts

Todos

  • support both axes in direction detection (currently only y)
  • add intersectenter & intersectleave events
@vnphanquang vnphanquang self-assigned this Jan 11, 2023
@vnphanquang vnphanquang added this to the Anytime milestone Jan 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Todo
Development

No branches or pull requests

1 participant