Routes can be defined using the functional API by getting an instance of the HttpRouterRegistry
and using its methods to define routes. For example:
const app = new App({ imports: [new FrameworkModule()] }); const router = app.get(HttpRouterRegistry); router.get('/user/:id', (id: number, database: Database) => { // Route logic }); app.run();