method ILifecycleApi.onRequest
ILifecycleApi.onRequest(fn: (ctx: IRequestContext) => void | Promise<void>): void

Runs at the start of every request.

Parameters

fn: (ctx: IRequestContext) => void | Promise<void>

Hook body receiving the request context

Return Type

void

Usage

import { type ILifecycleApi } from "common/src/index.ts";