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: Create useVisibilityObserver #122

Merged
merged 8 commits into from
Nov 9, 2022

Conversation

marichka-offen
Copy link
Contributor

This PR adds the useVisibilityObserver composition that is based on useIntersectionObserver composition to abstract away the logic for creating and connecting an IntersectionObserver and returns a boolean value if the target element is visible

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Copy link
Contributor

@pleek91 pleek91 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! Couple thoughts about making this a little more generic but this will be so nice to use in our projects

Co-authored-by: pleek91 <pleek91@gmail.com>
@pleek91
Copy link
Contributor

pleek91 commented Nov 9, 2022

@marichka-offen thank you so much! One very last thing (I promise). Can you add a link to this new composition in the rood README.md?

@marichka-offen
Copy link
Contributor Author

Ofc!

@marichka-offen
Copy link
Contributor Author

@pleek91 README is updated

Copy link
Contributor

@pleek91 pleek91 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

THANK YOU!

@pleek91 pleek91 merged commit f5aea66 into main Nov 9, 2022
@pleek91 pleek91 deleted the useVisibilityObserver-composition branch November 9, 2022 20:48
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.

None yet

2 participants