Intermediate interview questions in Node.js & Express, page 4
Nested routes versus query params for related resources
Nested routes express ownership and scope clearly, query params on the flat resource are flexible for filtering and combining.
Defining many-to-many relationships in Sequelize
Use belongsToMany through a join table, the through table holds the foreign keys, eager-load courses with include.
JWT login and protected route flow in Express
Verify credentials, sign a JWT, client stores and sends it (Authorization header or httpOnly cookie), middleware verifies signature on protected routes.
Unit testing Express auth middleware in isolation
Build fake req/res, use a spy/mock for next and res methods, assert next called on valid token and 401 sent on invalid.
Diagnosing intermittent crashes with PM2
PM2 auto-restarts and runs cluster mode for availability, inspect logs and metrics, watch memory for leaks, capture errors.
We are hiring for this. Every open role lists the topics its interview covers, so you can prepare for the real thing rather than guessing.
See open roles