Interview Q&A / Node.js

INTERVIEW Q&A · 68 QUESTIONS

Node.js interview questions

The event loop on the server, streams, modules and building APIs with Express.

  1. What is middleware in Express.js and how does next() work?

    Middleware is a function that runs between the request arriving and the response being sent. It receives req, res and next, and it either ends the response or calls next() to pass control to the next middleware or route. Calling next(err) jumps to error-handling middleware.

    BeginnerIn-depth2 min read