Timeout

Instance of

Class

Inherits from

Promise

Description

Asynchronously waits for the given amount of time (in milliseconds). Completes after finishing waiting.

Example

// Wait for ms
Timeout(1).then(() => console.write(1););
console.write(0);
await Timeout(23);
console.write(23);

Expected output

0123

Members

Inherited members

Properties

  • classPrototype