4 ms·
Sleep.js: JavaScript port of PHP sleep() function in 6 LOC
- taf2 9y agoThis is a really bad idea. CPU burning while you wait. A better approach is setTimeout or requestAnimationFrame.
- Horlahcoded 9y agoWhy @taf2 ? setTimeout is asynchronous, code after it will be executed before the function...requestAnimationFrame is for animations.
- elsyms 9y agoWhy?