Decorator-based routing
Controllers, route methods and parameter decorators, with DTOs validated and whitelisted by compiled, class-validator-compatible decorators.
Decorator-based routing, dependency injection, validation and OpenAPI docs, with minimal boilerplate.
import { ApiController, Get } from '@meghjs/core';
@ApiController
export class WelcomeController {
@Get()
sayHello() {
return 'Hello, Megh!';
}
}import { Megh } from '@meghjs/core';
import { WelcomeController } from './welcome.controller';
const app = Megh.createApplication();
app.useControllers([WelcomeController]);
app.run(); // or app.run(4000)