What the heck is the event loop anyway?

Recently, I have watched a valuable presentation about JavaScript's event loop. JavaScript is a one-threaded synchronous language. Keeping that in mind, have you wondered why some functions seem asynchronous? Why does setTimeout(0) help so many times? How to avoid browser's freezing?

event loopRecently, I have watched a valuable presentation about JavaScript's event loop. JavaScript is a one-threaded synchronous language. Keeping that in mind, have you wondered why some functions seem asynchronous? Why does setTimeout(0) help so many times? How to avoid browser's freezing? You will find answers to those questions in this short video.

 

 

We use cookies

We use cookies on our website. Some of them are essential for the operation of the site, while others help us to improve this site and the user experience (tracking cookies). You can decide for yourself whether you want to allow cookies or not. Please note that if you reject them, you may not be able to use all the functionalities of the site.