30-seconds-of-code
Version:
A collection of useful JavaScript snippets.
5 lines (3 loc) • 356 B
Markdown
### Event-driven programming
Event-driven programming is a programming paradigm in which the flow of the program is determined by events (e.g. user actions, thread messages, sensor outputs).
In event-driven applications, there is usually a main loop that listens for events and trigger callback functions accordingly when one of these events is detected.