Do you like reeding books? Full review of different kinds of books: technical, fantasy, fiction, etc.

Let's jump in the books world

55 non-standard Node.js interview questions for Node.js backend developers

Very interesting set of non-standard Node.js interview questions for backend developers and for Node.js system software developers which were created by Timur Shemsedinov (CTO at QOTEQ, Salucyber, Metatech; Architect at Metarhia and Metactos; Lecturer at KPI, KSE). From my point of view you can use these questions during the interview and for preparation for the interview.

Today I am publishing the first part - 55 questions for Node.js backend developers.

  1. What can you do by using for await with request: IncomingMessage object?
  2. How can you hash passwords in Node.js and when you need to use third-party dependencies for it?
  3. Which API implements nodejs/undici?
  4. What can you use instead of node:domain API?
  5. When can we use synchronous operations with files from node:fs instead of asynchronous operations and what to pay attention to taking this decision?
  6. Explain the best practices for processing the errors in asynchronous code.
  7. How vulnerabilities can appear in projects on Node.js? Explain please, what are XSS, Path traversal, SQL injection, CSRF? How can we protect apps from these?
  8. What do you know about race condition in asynchronous programming? How can we protect from it?
  9. Pros and cons dividing the code on .js and .d.ts.
  10. Tell please several typical Node.js patterns (according to GoF and not only) with examples.
  11. Explain the problem of the fat controllers (with examples on Node.js).
  12. Tell please some examples of the leaky abstractions (typical for Node.js).
  13. How to create a Singleton by using the module system in Node.js.
  14. How to easier implement the Strategy pattern on JavaScript and where to use it in Node.js?
  15. Give an example of Adapter pattern from core Node.js libraries (there are several).
  16. Which design pattern is implement the EventEmitter?
  17. Explain relationship between EventEmitter and Readable contracts.
  18. What antipatterns (or examples of bad style) of programming for Node.js can you give?
  19. Why do these Error fields need: error.cause, error.code, error.message, error.stack?
  20. How can you copy a folder with subfolders and files using node:fs?
  21. Can we make real-time applications by using Node.js?
  22. What approaches do you know for Logging? Differences, pros and cons.
  23. Where do we need to store secrets (api keys, tokens, passwords for Database, etc.)?
  24. How do not block all users during the processing of a request from one of them?
  25. Why do we need to do return await inside asynchronous functions and methods instead of returning a Promise?
  26. What do we need to do if during the request processing we need to abort the process (though it processes a lot of requests in parallel)?
  27. Which programming styles and paradigms do you use in Node.js applications? Why?
  28. Which weak sides of Node.js do you know? What is bad or impossible to write on Node.js?
  29. What is the difference between stateful and stateless approaches for Node.js applications? How can we choose between them?
  30. How can you limit the throughput of an endpoint (the number of requests per unit of time)?
  31. What are dangerous mixins for the application code (with typical examples on Node.js)?
  32. How do you implement the layered architecture in Node.js applications?
  33. What is Dependency Injection and how to implement it in Node.js (it is desirable to make it several ways)?
  34. Why is middleware an antipattern? How can we write code without one?
  35. How can we reduce code coupling in Node.js applications?
  36. Why do we need to add node: prefix during the loading core modules?
  37. Why do you need an AbortController? Give several examples AbortController is using.
  38. JSON serialization and deserialization can work a long time and can block a thread. What do you do with it?
  39. Why can all database connections leak from the Database connection pool and how to prevent this situation?
  40. How do you implement a data access layer?
  41. What is the advantage of the async/await and promises over callbacks in Node.js? Where is it impossible to do without a callback?
  42. What will you do if in two places of the one application you need different versions of the npm dependencies?
  43. Which Web API was added to Node.js during the last time and why?
  44. What can you use instead of outdated pm2 and forever in a modern world?
  45. How can a business logic be independent from a framework or a protocol through which requests come?
  46. Why do we not need axios, request, node-fetch in Node.js applications?
  47. Why do we need to use queues inside applications and external MQ systems?
  48. What is it bad when the dependency patches global objects, classes, prototypes?
  49. What is Node.js LTS and which benefits it gives to us?
  50. Why do we need to use Websocket? Why is using socket.io in 2023 a bad practice and what we need to use by working with Websocket?
  51. What does the --watch flag?
  52. In what condition is the native test runner in Node.js?
  53. Can we create an app as a single executable file in Node.js? How and why?
  54. What ways to track the asynchronous contexts do you know? Are they necessary at all?
  55. When and how do we need to update Node.js versions at apps?

Buy me a cup of coffee 😉

PayPal: s.minlevskiy@gmail.com

Berlin relocation Guide

How to receive a German Tax number, open bank account, apply for a Blue Card, setup German health insurance? What additional insurance do you need? How to get a local phone number? Many more is covered!

Learn more...

Serhii's blog. My thoughts about life and IT.

Please, write me: mydevthoughts@gmail.com