From fbebf2450d1dce2bd70ca5ffa633a125ab440685 Mon Sep 17 00:00:00 2001 From: Harminder Virk Date: Sun, 15 Dec 2024 08:16:09 +0530 Subject: [PATCH] refactor: display of route handler --- src/cli_formatters/routes_list.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/cli_formatters/routes_list.ts b/src/cli_formatters/routes_list.ts index 80fcb03f..4a0d680e 100644 --- a/src/cli_formatters/routes_list.ts +++ b/src/cli_formatters/routes_list.ts @@ -247,7 +247,9 @@ export class RoutesListFormatter { * Formats controller name for the ansi list and table */ #formatControllerName(route: SerializedRoute) { - return route.handler.type === 'controller' ? ` ${route.handler.moduleNameOrPath}.` : '' + return route.handler.type === 'controller' + ? ` ${this.#colors.cyan(route.handler.moduleNameOrPath)}.` + : '' } /** @@ -260,7 +262,7 @@ export class RoutesListFormatter { const functionName = ` ${this.#colors.cyan(route.handler.name)}` if (route.handler.args) { - return ` ${functionName}(${route.handler.args})` + return ` ${functionName}${this.#colors.dim(`(${route.handler.args})`)}` } return functionName