The number of milliseconds to sleep.
A promise that resolves after the specified time.
async function main() {
console.log('Start');
await sleep(2000); // Sleep for 2 seconds
console.log('End'); // Printed after sleep
}
main();
Generated using TypeDoc
Sleeps for the specified number of milliseconds.