diff --git a/doc/api/timers.md b/doc/api/timers.md index b710dec81533c8..21226257dd7c6f 100644 --- a/doc/api/timers.md +++ b/doc/api/timers.md @@ -188,14 +188,14 @@ async function timerExample() { timerExample(); ``` -### `setInterval(callback, delay[, ...args])` +### `setInterval(callback[, delay[, ...args]])` * `callback` {Function} The function to call when the timer elapses. * `delay` {number} The number of milliseconds to wait before calling the - `callback`. + `callback`. **Default**: `1`. * `...args` {any} Optional arguments to pass when the `callback` is called. * Returns: {Timeout} for use with [`clearInterval()`][] @@ -206,14 +206,14 @@ set to `1`. Non-integer delays are truncated to an integer. If `callback` is not a function, a [`TypeError`][] will be thrown. -### `setTimeout(callback, delay[, ...args])` +### `setTimeout(callback[, delay[, ...args]])` * `callback` {Function} The function to call when the timer elapses. * `delay` {number} The number of milliseconds to wait before calling the - `callback`. + `callback`. **Default**: `1`. * `...args` {any} Optional arguments to pass when the `callback` is called. * Returns: {Timeout} for use with [`clearTimeout()`][]