The function to delay.
The number of milliseconds to delay invocation.
Rest
...args: Parameters<T>The arguments to invoke func
with.
Rest
Returns the timer id.
5.7.0
delay(text => console.log(text), 1000, 'later')
// => Logs 'later' after one second.
Invokes
func
afterwait
milliseconds. Any additional arguments are provided tofunc
when it's invoked.