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

timeRemaining() documentation should flag that it doesn't just count down #37250

Open
jyasskin opened this issue Dec 17, 2024 · 0 comments
Open
Labels
Content:WebAPI Web API docs needs triage Triage needed by staff and/or partners. Automatically applied when an issue is opened.

Comments

@jyasskin
Copy link
Contributor

MDN URL

https://developer.mozilla.org/en-US/docs/Web/API/IdleDeadline/timeRemaining

What specific section or headline is this issue about?

No response

What information was incorrect, unhelpful, or incomplete?

The text implies that the "current idle period" is a fixed period, and the method just counts down to the end of it. But in fact, it uses an algorithm passed from https://html.spec.whatwg.org/multipage/webappapis.html#event-loop-processing-model that can suddenly jump to zero. I don't think it can increase, but you might want to check with the spec authors to be sure of that.

What did you expect to see?

A description of what asynchronous changes to expect from the return value of this method.

Do you have any supporting links, references, or citations?

w3c/requestidlecallback#104

Do you have anything more you want to share?

No response

MDN metadata

Page report details
@jyasskin jyasskin added the needs triage Triage needed by staff and/or partners. Automatically applied when an issue is opened. label Dec 17, 2024
@github-actions github-actions bot added the Content:WebAPI Web API docs label Dec 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Content:WebAPI Web API docs needs triage Triage needed by staff and/or partners. Automatically applied when an issue is opened.
Projects
None yet
Development

No branches or pull requests

1 participant