Async Code in Node.js: Callbacks and Promises
JavaScript runs on a single thread.
That means it executes one task at a time.
So a big question appears:
How does Node.js handle file reading, APIs, databases, or timers without freezing the entire
blog.dhiraj.dev5 min read