@axonlabs/core
    Preparing search index...

    Type Alias FuncController<P>

    FuncController: (
        request: Request<P>,
        response: Response,
        ...args: any[],
    ) => Promise<void> | void

    FuncController type represents a function controller used in routing. It defines a function type that takes two parameters: a Request object and a Response object, and returns a Promise<void> or void. This type is commonly used to define the handler functions for different routes in a web application. The Request object contains information about the incoming request, such as method, path, params, query, and body. The Response object provides methods to send responses back to the client. The FuncController type is generic, allowing you to specify the type of parameters (P) that the controller function expects.

    Type Parameters

    • P = {}

    Type declaration

      • (request: Request<P>, response: Response, ...args: any[]): Promise<void> | void
      • Parameters

        Returns Promise<void> | void