Skip to content
AgileLogics
5 min read

Server-Side JavaScript with Node

Prerequisites: Node.js and npm, API design

Express is the most widely used Node framework for building a web server/API.

import express from "express";

const app = express();
app.use(express.json());

app.get("/users/:id", (req, res) => {
    res.json({ id: req.params.id, name: "Ada" });
});

app.listen(3000, () => console.log("Server running on port 3000"));

This is the same JavaScript you already know — running as a long-lived server process instead of a page loaded in a browser tab.