3 ms·
No, it’s more like calling „setTimeout(…,0)“ to allow for the JS runtime to process the event loop before you return to your CPU intensive math.
by G3rn0ti 5y ago
No, it’s more like calling „setTimeout(…,0)“ to allow for the JS runtime to process the event loop before you return to your CPU intensive math.
- neolog 5y agoYeah that's more precise. `await sleep(0)` is pretty common, it's a good feature.