Files
Snacks-Analytics-backend/src/server.ts
AlexLoup 15fde72f08 Package, Server, Routes
Adding the base of the server program
2026-06-14 19:14:35 +02:00

23 lines
720 B
TypeScript

import express from "express";
// ----------------------------------------
// Backend configuration
// ----------------------------------------
const PORT = 5000;
const app = express();
// ----------------------------------------
// Middleware configuration
// ----------------------------------------
app.use(express.json());
app.use(express.urlencoded( {extended: false }));
// ----------------------------------------
// Routes import
// ----------------------------------------
app.use("/status", require("./routes/status.routes"));
// ----------------------------------------
// Starting Server
// ----------------------------------------
app.listen(PORT, () => console.log("Server started at port : " + PORT));