what is event driven programming in node js

Solutions on MaxInterview for what is event driven programming in node js by the best coders in the world

showing results for - "what is event driven programming in node js"
Tina
15 Jan 2019
1// event-driven programming in node
2
3-> Event-driven programing: 
4In computer programming, event-driven programming is a programming paradigm 
5in which the flow of the program is determined by events such as user actions 
6(mouse clicks, key presses), sensor outputs, or message passing from other 
7programs or threads
8
9-> Event-driven programming in node:
10- Node.js uses events heavily and it is also one of the reasons why 
11Node.js is pretty fast compared to other similar technologies.
12
13-As soon as Node starts its server, it simply initiates its variables,
14declares functions and then simply waits for the event to occur.
15
16In an event-driven application, there is generally a main loop that
17listens for events, and then triggers a callback function when one
18of those events is detected.