Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

sleep js

const sleep = ms => new Promise(r => setTimeout(r, ms));
sleep(5000)

OR

> npm i sleepjs

const { sleep } = require('sleepjs')
await sleep(500)
 
PREVIOUS NEXT
Tagged: #sleep #js
ADD COMMENT
Topic
Name
7+9 =