Function expressRouter

  • Main function to configure an Express router with dynamic routes.

    Parameters

    • routesObject: IRoutesObject

      The routes object containing route definitions.

    • config: {
          afterProcess: undefined | ((tn: string, a: string, data: any, i: string) => any);
          beforeProcess: undefined | ((tn: string, a: string, data: any, i: string) => any);
          debugLog: undefined | boolean;
          router: undefined | Router;
      } = {}

      Configuration options for the router.

      • afterProcess: undefined | ((tn: string, a: string, data: any, i: string) => any)
      • beforeProcess: undefined | ((tn: string, a: string, data: any, i: string) => any)
      • debugLog: undefined | boolean
      • router: undefined | Router

    Returns Router

    The configured Express router.