Serilog - Console Sink Themes

Curious about how each theme in Serilog.Sinks.Console looks like? Check them here.

commit a3a4315 · authored · 1 min read

Serilog - Console Sink Themes

Serilog is my favorite logger. The sinks I was using are ApplicationInsights, File, and Seq (for local). I was not using Console sink but when we switched to docker, I thought it is nice to have Console too.

I was checking the colored output for Console and I realized that the serilog-sinks-coloredconsole is retired and the Serilog.Sinks.Console by default has the colored output. There were few color themes listed on the readme so I want to see how each looks like, and see it for yourself below.

Built-in Themes

SystemConsoleTheme.Literate (Default)

.WriteTo.Console()

OR

.WriteTo.Console(theme: SystemConsoleTheme.Literate)
SystemConsoleTheme.Literate
SystemConsoleTheme.Literate

ConsoleTheme.None

.WriteTo.Console(theme: ConsoleTheme.None)
ConsoleTheme.None
ConsoleTheme.None

SystemConsoleTheme.Grayscale

.WriteTo.Console(theme: SystemConsoleTheme.Grayscale)
SystemConsoleTheme.Grayscale
SystemConsoleTheme.Grayscale

AnsiConsoleTheme.Literate

.WriteTo.Console(theme: AnsiConsoleTheme.Literate)
AnsiConsoleTheme.Literate
AnsiConsoleTheme.Literate

AnsiConsoleTheme.Grayscale

.WriteTo.Console(theme: AnsiConsoleTheme.Grayscale)
AnsiConsoleTheme.Grayscale
AnsiConsoleTheme.Grayscale

AnsiConsoleTheme.Code

.WriteTo.Console(theme: AnsiConsoleTheme.Code)
AnsiConsoleTheme.Code
AnsiConsoleTheme.Code

Final Notes

In the above list, my favorite so far is the default one. I didn’t try any custom themes yet. if you know any good looking custom themes, let me know in the comments 👇

Additional Resources

local graph · open full graph

"Serilog - Console Sink Themes" is connected to the topics Serilog, ASP.NET Core, Logging and related to 6 other entries. ASP.NET Core - OAuth 2.0 Client Access Token Management ASP.NET Core - OAuth 2.0 Cl… ASP.NET Core - Using Mutliple Authentication Schemes ASP.NET Core - Using Mutlip… Azure DevOps Build - Could not locate the assembly Azure DevOps Build - Could … .NET Core API Gateway Ocelot - Logging HTTP Requests & Response Including Headers & Body .NET Core API Gateway Ocelo… ASP.NET Core - Return 500 (Internal Server Error) or any other Status Code from API ASP.NET Core - Return 500 (… Docker - SQL Error on ASP.NET Core Alpine Docker - SQL Error on ASP.N… Serilog #serilog ASP.NET Core #aspnet-core Logging #logging Serilog - Console Sink Themes

webmentions · 7 mentions

  • Someone · Oct 16, 2022 · mention

    To protect their business reputation, most companies invest a lot of money to make sure you can log in securely and use your account. What you need to pay attention to is whether your network is secure and visits the correct website address. Here’s the information that has been manually reviewed about serilog console color english : GitHub – serilog/serilog-sinks-console: Write log events … h

  • Someone · Oct 12, 2022 · mention

    Securing your online account is no different than protecting your house and car, but most people don’t know where to start. Here’s a simple advice: don’t give away personal information unless you proactively contact a company by email or phone. A common example is an unsolicited email telling you that if you don’t respond right away, you’ll lose access or be at risk. Here is the information about

  • Someone · Oct 03, 2022 · mention

    Securing your online account is no different than protecting your house and car, but most people don’t know where to start. Here’s a simple advice: don’t give away personal information unless you proactively contact a company by email or phone. A common example is an unsolicited email telling you that if you don’t respond right away, you’ll lose access or be at risk. Here is the information about

  • Someone · Sep 22, 2022 · mention

  • Someone · Sep 22, 2022 · mention

  • Someone · Mar 22, 2022 · mention

    Everyone uses at least 10 or more online services per day, such as: email, banking online, shopping sites, and more. After you log in, many websites keep you logged in for more than 24 hours by default, because frequent logins reduce the user experience. You need to remember to sign out for important accounts to protect it. GitHub – serilog/serilog-sinks-console: Write log events … https://gith

  • Someone · Mar 12, 2022 · mention

comments

loading discussion…