chore: rename to template

This commit is contained in:
afiqzudinhadi 2025-06-19 16:51:10 +08:00
parent 063dfe39e9
commit c011186c37
46 changed files with 143 additions and 142 deletions

View file

@ -1,22 +0,0 @@
import { json, urlencoded } from "body-parser";
import express, { type Express } from "express";
import morgan from "morgan";
import cors from "cors";
export const createServer = (): Express => {
const app = express();
app
.disable("x-powered-by")
.use(morgan("dev"))
.use(urlencoded({ extended: true }))
.use(json())
.use(cors())
.get("/message/:name", (req, res) => {
return res.json({ message: `hello ${req.params.name}` });
})
.get("/status", (_, res) => {
return res.json({ ok: true });
});
return app;
};