Skip to content

Commit a6da5fd

Browse files
committed
fixup! doc: remove "idiomatic choice" from queueMicrotask
1 parent 385510b commit a6da5fd

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

doc/api/globals.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,8 +122,10 @@ The `queueMicrotask()` method queues a microtask to invoke `callback`. If
122122
`callback` throws an exception, the [`process` object][] `'uncaughtException'`
123123
event will be emitted.
124124

125-
`process.nextTick()` will always run before the microtask queue, and so
126-
unexpected execution order may be observed.
125+
The microtask queue is managed by V8 and may be used in a similar manner to
126+
the `process.nextTick()` queue, which is managed by Node.js. The
127+
`process.nextTick()` queue is always processed before the microtask queue
128+
within each turn of the Node.js event loop.
127129

128130
```js
129131
// Here, `queueMicrotask()` is used to ensure the 'load' event is always

0 commit comments

Comments
 (0)