Skip to main content

Automatically generate comprehensive documentation for your .NET application configuration settings. Keep your 'appsettings.json' files documented, validated, and always up-to-date with JSON schemas, Markdown, and HTML documentation.

Total Downloads
1.7K
1,746
Published
May 21, 2026
6mo ago

Get Started

dotnet add package TomsToolbox.Settings.Documentation.Analyzer --version 1.1.0

No framework information available.

README

TomsToolbox.Settings.Documentation.Analyzer

Roslyn analyzer that helps ensure your configuration classes are properly annotated for automatic documentation generation.

Overview

This analyzer provides compile-time diagnostics and code fixes to help you maintain consistent and complete documentation of your application's configuration settings. It works in conjunction with the Settings.Documentation library to ensure all configuration options are discoverable and well-documented.

Diagnostics

CONF001: Missing [SettingsSection] Attribute

Severity: Warning

Warns when a configuration options class used with AddOptions<T>() is missing the [SettingsSection] attribute.

Code Fix: Automatically adds the [SettingsSection] attribute to the class.

CONF002: Missing Description

Severity: Warning

Warns when a property in a configuration options class lacks a [Description] attribute, which is used for documentation generation.

Code Fix: Automatically adds a [Description] attribute placeholder to the property.

CONF003: Missing [SettingsAddOptionsInvocator] Attribute

Severity: Warning

Warns when a method that invokes AddOptions<T>() is missing the [SettingsAddOptionsInvocator] attribute, making it non-discoverable for documentation generation.

Code Fix: Automatically adds the [SettingsAddOptionsInvocator] attribute to the method.

Installation

Install via NuGet:

dotnet add package TomsToolbox.Settings.Documentation.Analyzer

The analyzer is automatically integrated into your build process and provides real-time feedback in Visual Studio, VS Code, and other IDEs that support Roslyn analyzers.

Requirements

  • .NET Standard 2.0 or higher
  • Microsoft.CodeAnalysis.CSharp 4.4.0 or higher

Related Packages

  • TomsToolbox.Settings.Documentation.Abstractions - Attribute definitions
  • TomsToolbox.Settings.Documentation.Builder - Runtime library for generating documentation

For more information, see the main repository documentation.

License

MIT License

Part of the TomsToolbox library suite.

Downloads by Version

Similar & Alternative Packages

Hand-picked matching NuGet libraries based on tags & ecosystem

Depended On By

Find packages that declare this package as a dependency. NuGet does not provide a reverse-dependency endpoint, so candidates are checked on demand.

Adoption Assessment

Assess this package against its supported frameworks, license, maintenance signals and dependency graph before making it a project standard.

No SPDX license expression is published. Review the license text and your organisation's policy before redistribution.No target framework metadata is available. Confirm compatibility in a representative project before standardising on this package.

Related Guides & Workflows

Learn how to evaluate, integrate, or audit this package in your .NET project.