CreateSleepPromise (open)
Asynchronous sleep (allows microtasks to run ie to allow promises to resolve)
Syntax
LOADLIB "wh::promise.whlib";
OBJECT FUNCTION CreateSleepPromise(INTEGER time)
Parameters
INTEGER time
Time to sleep, in milliseconds
Return value
OBJECT
A promise that resolves after the specified time