← Node.js & Express learning path
Node.js & Express · Module 4 of 10

Core modules: fs, path, http

Use Node's built-in modules to work with files and servers.

📖 Key ideas

  1. fs reads and writes files.
  2. path joins paths safely: path.join(__dirname, "data.json").
  3. http creates a basic web server.
  4. os and process give system and environment info.
  5. process.env reads environment variables.
💡 Real-life example: Core modules are the tools that come in the box with your new toolkit; no shopping needed.
fsFile system module
pathBuilds file paths safely
httpCreates servers and requests
process.envEnvironment variables