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

replace deprecated use of pageYOffset #1

Closed
Shrimpstronaut opened this issue Feb 18, 2022 · 1 comment
Closed

replace deprecated use of pageYOffset #1

Shrimpstronaut opened this issue Feb 18, 2022 · 1 comment
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@Shrimpstronaut
Copy link
Contributor

Description

The main library uses the pageYOffset property of the window to get the current scroll position. The property has been deprecated and should be replaced with scrollY.

windowatch/src/index.ts

Lines 569 to 586 in ab94e05

/**
* Triggered at each window scroll event.
*
* @protected
* @memberof TaikoLibWindowatch
*/
protected windowDidScroll = (): void => {
const scrollY = window.pageYOffset;
if (this.scrollY === scrollY) {
// nothing changed, nothing to do
return;
}
this.scrollY = scrollY;
this.scrollDidChange = true;
this.requestFrame();
};

@Shrimpstronaut Shrimpstronaut added the enhancement New feature or request label Feb 18, 2022
@Shrimpstronaut Shrimpstronaut self-assigned this Feb 18, 2022
@Shrimpstronaut Shrimpstronaut added this to the v2.0.0 milestone Feb 18, 2022
@Shrimpstronaut
Copy link
Contributor Author

Due to IE11 support, the proposed change will not be merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant