vivek
  • 0
Beginner

What is an Event loop in Node ?

  • 0

Event loop

  1. The event loop is what allows Node.js to perform non-blocking I/O operations — even though JavaScript is single-threaded — by offloading operations to the system kernel whenever possible.

    When one of these operations completes, the kernel tells Node.js so that the appropriate callback may be added to the poll queue to eventually be executed. We’ll explain this in further detail later in this topic.

    Event Loop is a program, which allows subscribing to system resource events. It provides a callback stack that can be linked to resources and executed when appropriate descriptors are ready.

    The Event Loop abstraction might be already known to JavaScript developers as the concept is widely used in programming applications for browsers.

    • 1

You must login to add an answer.