-
-
Notifications
You must be signed in to change notification settings - Fork 35.4k
doc: fix recommendation of setImmediate() over process.nextTick() #30801
Copy link
Copy link
Closed
nodejs/nodejs.org
#2827Labels
docIssues and PRs related to the documentations.Issues and PRs related to the documentations.good first issueIssues that are suitable for first-time contributors.Issues that are suitable for first-time contributors.timersIssues and PRs related to the timers subsystem / setImmediate, setInterval, setTimeout.Issues and PRs related to the timers subsystem / setImmediate, setInterval, setTimeout.
Metadata
Metadata
Assignees
Labels
docIssues and PRs related to the documentations.Issues and PRs related to the documentations.good first issueIssues that are suitable for first-time contributors.Issues that are suitable for first-time contributors.timersIssues and PRs related to the timers subsystem / setImmediate, setInterval, setTimeout.Issues and PRs related to the timers subsystem / setImmediate, setInterval, setTimeout.
Is your feature request related to a problem? Please describe.
On this url:
At the
process.nextTick()section, it says:But this is untrue since
setImmediate()isn't supported in "wider variety of environments". Only supported in Edge & IE, but not Chrome, Firefox, Safari (on both desktop and mobile platforms).Describe the solution you'd like
Describe alternatives you've considered
setTimeoutandwindow.requestAnimationFrameare the nearest alternatives forsetImmediatefor the browser, but I don't know how to phrase it yet