MicrosoftLogger.Analyzer
1.0.2
dotnet add package MicrosoftLogger.Analyzer --version 1.0.2
NuGet\Install-Package MicrosoftLogger.Analyzer -Version 1.0.2
<PackageReference Include="MicrosoftLogger.Analyzer" Version="1.0.2"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
<PackageVersion Include="MicrosoftLogger.Analyzer" Version="1.0.2" />
<PackageReference Include="MicrosoftLogger.Analyzer"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
paket add MicrosoftLogger.Analyzer --version 1.0.2
#r "nuget: MicrosoftLogger.Analyzer, 1.0.2"
#:package MicrosoftLogger.Analyzer@1.0.2
#addin nuget:?package=MicrosoftLogger.Analyzer&version=1.0.2
#tool nuget:?package=MicrosoftLogger.Analyzer&version=1.0.2
MicrosoftLogger.Analyzer
Analyzer helps you to find ILogger<TCategoryName> with wrong category name and fix it
Installation
To install MicrosoftLogger.Analyzer, run the following command:
dotnet add package MicrosoftLogger.Analyzer
Description
When you use Microsoft.Extensions.Logging.ILogger<TCategoryName>, you usually resolve it from dependency injection and set current class as the generic parameter.
The class is used as a category name in logs. You can filter logs by category, you can set a specific log level for category. Because of that, you must set the right class for the generic parameter of ILogger.
Often there are mistakes in ILogger<TCategoryName>. MicrosoftLogger.Analyzer analyzes class constructors and helps you to find and fix mistakes.

Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Thanks to Gérald Barré(@meziantou) for helping improve performance of the analyzer