Quickstart
Register @quik/http-express alongside @quik/http in your bootstrap module list; the module wires up the Express
engine as the active IQHTTPEngine feature automatically:
import { Module as HttpExpress } from '@quik/http-express';
await HttpExpress.setup({ /* bootstrap options */ });
Define a route using the shared @quik/http decorators — routes are engine-agnostic, @quik/http-express only
supplies the runtime that executes them:
import { Decorators, QRoute } from '@quik/http';
@Decorators.Route.Route('/health')
export class HealthRoute extends QRoute {
@Decorators.Endpoint.GET('/')
async get() {
return { status: 'ok' };
}
}
Notes
@quik/httpmust be installed and loaded before@quik/http-express(declared as aDependenciesentry inmodule.ts).- The module only activates when an
IQHTTPEnginefeature has not already been set — checkhasFeature('IQHTTPEngine')if you need to guard custom setup. - Attach Express-specific middleware with
ExpressMiddlewareUtils.RouteMiddleware()/.EndpointMiddleware(); these are Express-only and not part of@quik/http's engine-agnostic decorator set.