Добавить
Уведомления

what is event loop || event লুপ কি

I am trying to make it simple by javascript event loop. When we write javascript code we run it in web browser or code editor. When the code is run, it is converted to machine language by the engine in the web browser. No problem, we are running with Chrome browser v8 engine. And v8 engine two parts are Heap and another is Call Stack and Call Stack (lifo=last in fast out) works as. The call stack is when a function is called in javascript code When I call, the call stack starts accumulating. Whoever comes first calls. It is said to be given synchronously. There are also some asynchronous ones such as: when I call the setTimeout function, then it is kept aside, baby, I will call you after a while, it means waiting. The function is passed to the Callback Queue Callback Queue (fifo = fast in fast out) works. Why don't we mention Call Stack for so long? Haven't called yet. If you don't call, it won't work So the event loop is doing the calling in Call Stack.

Иконка канала Кодерские решения
8 подписчиков
12+
16 просмотров
2 года назад
12+
16 просмотров
2 года назад

I am trying to make it simple by javascript event loop. When we write javascript code we run it in web browser or code editor. When the code is run, it is converted to machine language by the engine in the web browser. No problem, we are running with Chrome browser v8 engine. And v8 engine two parts are Heap and another is Call Stack and Call Stack (lifo=last in fast out) works as. The call stack is when a function is called in javascript code When I call, the call stack starts accumulating. Whoever comes first calls. It is said to be given synchronously. There are also some asynchronous ones such as: when I call the setTimeout function, then it is kept aside, baby, I will call you after a while, it means waiting. The function is passed to the Callback Queue Callback Queue (fifo = fast in fast out) works. Why don't we mention Call Stack for so long? Haven't called yet. If you don't call, it won't work So the event loop is doing the calling in Call Stack.

, чтобы оставлять комментарии