Skip to content

fix(useIntersectionObserver)!: update the threshold default to 0 #4069

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

Merged
merged 2 commits into from
Jul 17, 2024
Merged

fix(useIntersectionObserver)!: update the threshold default to 0 #4069

merged 2 commits into from
Jul 17, 2024

Conversation

Alfred-Skyblue
Copy link
Member

Description

resolve #2184

According to the MDN documentation on the IntersectionObserver API, the default value of threshold should be 0. In #115, I did not find any discussion regarding threshold defaulting to 0.1. Should we maintain consistency with the IntersectionObserver API's default value? However, this would be a breaking change.

https://developer.mozilla.org/en-US/docs/Web/API/Intersection_Observer_API#threshold

@dosubot dosubot bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label Jun 27, 2024
@antfu antfu changed the title refactor(useIntersectionObserver)!: update the threshold default to 0 fix(useIntersectionObserver)!: update the threshold default to 0 Jul 17, 2024
@antfu antfu enabled auto-merge July 17, 2024 13:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm This PR has been approved by a maintainer size:XS This PR changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants