{
res.send("Hello World");
},
});
AppRouter.Execute(app); // ? or app.use("/const express = require("express");
const Router = require("express-router-plugin");
const app = express();
const AppRouter = new Router();
AppRouter.Init({
inbuild_error_handler: true,
ApplyDefaultRateLimit: false,
SafeMode: false
})
AppRouter.CreateRoute({
endpoint: "/",
Middleware: [],
controller: (req, res) => {
res.send("Hello World");
},
});
AppRouter.Execute(app); // ? or app.use("/<Your Endpoint>" , AppRouter.Execute());
app.listen(3000, () => {
console.log("Server Started at <http://localhost:3000>");
})
module.exports = app;