nx.js
Functions

setTimeout

setTimeout(handler, timeout, ...args): number

The global setTimeout() method sets a timer which executes a function or specified piece of code once the timer expires.

Parameters

ParameterTypeDefault valueDescription
handlerTimerHandlerundefinedThe function or string to be executed after the timer expires.
timeoutnumber0The time, in milliseconds, the timer should wait before the specified function or code is executed. If this parameter is omitted, a value of 0 is used.
...argsany[]undefinedAdditional arguments to be passed to the function specified by the handler parameter.

Returns

number

The numeric ID of the timer, which can be used later with the clearTimeout() method to cancel the timer.

See

https://developer.mozilla.org/docs/Web/API/setTimeout

On this page