Node.js
Understand Node.js from the inside: modules, npm, the event loop, files and streams, then build, secure, test and deploy HTTP APIs. Every runnable example uses transparent Node built-ins with no hidden packages.
Every chapter is an island. Finish its lessons, beat its challenge, and sail on ⛵
Island 1
Runtime and core tooling
- What is Node.js?V8, libuv and built-ins, and why Node is not a browser on the server.10 min2 🎮
- CommonJS and ES modulesSplit programs behind clear contracts and understand require/export and import/export.11 min2 🎮
- npm and package.jsonDescribe a project, its scripts and dependencies, and lock versions correctly.11 min2 🎮
- process and command-line appsRead arguments and environment, set exit codes, and clean resources before exit.10 min2 🎮
Island 2
Async I/O and events
- Event loop: callbacks to async/awaitUnderstand execution order and write asynchronous flow without callback hell.13 min2 🎮
- Files and paths with fs/promisesRead and write safely, and build paths that work across operating systems.12 min2 🎮
- EventEmitterDecouple producers from listeners, and understand synchrony and listener cleanup.10 min2 🎮
- Streams and backpressureProcess large data chunk by chunk instead of buffering it all in memory.12 min2 🎮
Island 3
HTTP and APIs
- Your first HTTP serverReceive a request and send status, headers and a body with node:http.12 min2 🎮
- Routing and JSON bodiesChoose handlers by method and pathname, and read bounded request bodies.13 min2 🎮
- Build a tiny router and middleware chainUnderstand what Express does: route matching and a next() middleware chain.14 min2 🎮
- REST: resources and status codesDesign noun-based URLs and use verbs and status codes as stable contracts.11 min2 🎮
- Validation and error handlingSeparate client mistakes from server faults and return a stable error shape.12 min2 🎮
Island 4
Production: security, testing and deployment
- Authentication basics with cryptoHash passwords correctly and understand signed tokens without inventing production auth.14 min2 🎮
- Configuration and environment secretsSeparate configuration from code, validate it at startup, and keep secrets out of logs.10 min2 🎮
- Testing with assert and node:testTest behavior quickly and separate unit from integration tests without noisy output.12 min2 🎮
- API security fundamentalsPrevent injection and configure CORS, rate limits and headers without false confidence.14 min2 🎮
- Project: tasks REST API and deploymentCombine server, routing, validation and tests, then prepare it for Render or Vercel.18 min2 🎮