@@ -49,25 +49,26 @@ milliseconds (approximately 25 days) or less than 1, Node.js will use 1 as the
4949
5050## setTimeout(callback, delay[, arg][, ...])
5151
52- To schedule execution of a one-time `callback` after `delay` milliseconds. Returns a
53- `timeoutObject` for possible use with `clearTimeout()`. Optionally you can
54- also pass arguments to the callback.
52+ To schedule execution of a one-time `callback` after `delay` milliseconds.
53+ Returns a `timeoutObject` for possible use with `clearTimeout()`. Optionally you
54+ can also pass arguments to the callback.
5555
56- It is important to note that your callback will probably not be called in exactly
57- `delay` milliseconds - Node.js makes no guarantees about the exact timing of when
58- the callback will fire, nor of the ordering things will fire in. The callback will
59- be called as close as possible to the time specified.
56+ The callback will likely not be invoked in precisely `delay` milliseconds.
57+ Node.js makes no guarantees about the exact timing of when callbacks will fire,
58+ nor of their ordering. The callback will be called as close as possible to the
59+ time specified.
6060
6161To follow browser behavior, when using delays larger than 2147483647
6262milliseconds (approximately 25 days) or less than 1, the timeout is executed
6363immediately, as if the `delay` was set to 1.
6464
6565## unref()
6666
67- The opaque value returned by [`setTimeout`][] and [`setInterval`][] also has the method
68- `timer.unref()` which will allow you to create a timer that is active but if
69- it is the only item left in the event loop, it won't keep the program running.
70- If the timer is already `unref`d calling `unref` again will have no effect.
67+ The opaque value returned by [`setTimeout`][] and [`setInterval`][] also has the
68+ method `timer.unref()` which will allow you to create a timer that is active but
69+ if it is the only item left in the event loop, it won't keep the program
70+ running. If the timer is already `unref`d calling `unref` again will have no
71+ effect.
7172
7273In the case of `setTimeout` when you `unref` you create a separate timer that
7374will wakeup the event loop, creating too many of these may adversely effect
0 commit comments