-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Type definition for ScrollBehavior appears to be wrong #28755
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
Comments
Closing as it looks like this is in fact correct. microsoft/TypeScript-DOM-lib-generator@fe01c9a MDN docs were just updated to reflect this. |
This seems to be wrong / still broken for scrollTo: https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollTo |
Will be fixed in 5.1: #47441 (comment) |
Currently on 5.2 and having this issue |
Is this still not added or re-broken? |
Please log a new issue using the appropriate template |
fixed in 5.1 as mentioned here 👌🏼 |
still an issue for me |
Raising this here as per contribution guidelines for the
TSJS-lib-generator
repohttps://github.com/Microsoft/TSJS-lib-generator#contribution-guidelines
To confirm that this is indeed an issue before I open a PR to fix it over there.
TypeScript Version: 3.2.1
Search Terms:
instant
scrollbehavior
types
type defs
type definitions
Code
Sans react code
Expected behavior:
scrollIntoViewOptions
optionbehavior
should allow the value'instant'
as it doesn't appear to be a deprecated value (according to MDN):https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollIntoView
Actual behavior:
node_modules/typescript/lib/lib.dom.d.ts
line17972
is defined astype ScrollBehavior = "auto" | "smooth";
previously the
ScrollBehavior
type was defined astype ScrollBehavior = "auto" | "instant" | "smooth";
which seems to be correct.
Playground Link:
Here
Related Issues:
The text was updated successfully, but these errors were encountered: