deno_std icon indicating copy to clipboard operation
deno_std copied to clipboard

Rework ConsoleHandler to use native console methods

Open nesk opened this issue 3 years ago • 0 comments

Is your feature request related to a problem? Please describe.

When using the log module with Deno Deploy, the output is not "native" in the dashboard:

Screenshot 2022-09-12 at 21-21-33 actions - Project - Deploy Redacted

Describe the solution you'd like

Deno Deploy provides a clean UI for logs outputed with the debug, info, warn, error methods, what about using those by default in ConsoleHandler?

Screenshot 2022-09-12 at 21-22-13 actions - Project - Deploy Redacted

Describe alternatives you've considered

The ConsoleHandler can be useful but in a terminal, what about renaming it TerminalHandler and creating a new ConsoleHandler?

  • TerminalHandler: always outputs with console.log and formats data by itself, like the current ConsoleHandler.
  • ConsoleHandler: outputs with the appropriate console.* methods, lets Deno Deploy handle the formatting.

The only drawback I can see is the missing critical method in the native console API.

nesk avatar Sep 12 '22 19:09 nesk