Skip to content

Commit ededcba

Browse files
committed
Fix ToC generation
1 parent 1c79be7 commit ededcba

6 files changed

Lines changed: 33 additions & 12 deletions

docs/NetEscapades.EnumGenerators.Generators.md

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,15 @@ In general, we recommend installing the [NetEscapades.EnumGenerators](https://ww
2222
* [Why use these packages?](#why-use-these-packages)
2323
* [Adding NetEscapades.EnumGenerators.Generators to your project](#adding-netescapadesenumgeneratorsgenerators-to-your-project)
2424
* [Controlling extension accessibility](#controlling-extension-accessibility)
25+
* [Usage Analyzers](#usage-analyzers)
2526
* [Enabling the analyzers](#enabling-the-analyzers)
2627
* [Configuring analyzer severity (optional)](#configuring-analyzer-severity-optional)
2728
* [Code fixes](#code-fixes)
29+
* [Package referencing options](#package-referencing-options)
2830
* [Avoiding runtime dependencies](#avoiding-runtime-dependencies)
2931
* [Choosing the correct packages for your scenario](#choosing-the-correct-packages-for-your-scenario)
30-
* [Enabling automatic interception (experimental)](#enabling-automatic-interception-experimental)<!-- endToc -->
32+
* [Enabling automatic interception (experimental)](#enabling-automatic-interception-experimental)
33+
* [Preserving usages of the `[EnumExtensions]` attribute](#preserving-usages-of-the-enumextensions-attribute)<!-- endToc -->
3134

3235
## Why use these packages?
3336

@@ -342,7 +345,8 @@ or for external enums:
342345
```
343346
<!-- endInclude -->
344347

345-
## Usage Analyzers<!-- include: usage-analyzers. path: /fragments/usage-analyzers.include.md -->
348+
<!-- include: usage-analyzers. path: /fragments/usage-analyzers.include.md -->
349+
## Usage Analyzers
346350

347351
_NetEscapades.EnumGenerators_ includes optional analyzers that encourage the use of the generated extension methods instead of the built-in `System.Enum` methods. These analyzers can help improve performance by suggesting the faster, generated, alternatives like `ToStringFast()`, `HasFlagFast()`, and `TryParse()`.
348352

@@ -412,7 +416,8 @@ All usage analyzers include automatic code fixes. When a diagnostic is triggered
412416

413417
![Demonstrating the code-fix option available in your IDE for each of the analyzers](https://raw.githubusercontent.com/andrewlock/NetEscapades.EnumGenerators/refs/heads/main/docs/images//code_fix.png)<!-- endInclude -->
414418

415-
## Package referencing options<!-- include: package-referencing. path: /fragments/package-referencing.include.md -->
419+
<!-- include: package-referencing. path: /fragments/package-referencing.include.md -->
420+
## Package referencing options
416421

417422
[NetEscapades.EnumGenerators](https://www.nuget.org/packages/NetEscapades.EnumGenerators) is a metapackage that references additional packages for functionality.
418423

@@ -634,7 +639,8 @@ public void CantIntercept()
634639
```
635640
<!-- endInclude -->
636641

637-
## Preserving usages of the `[EnumExtensions]` attribute<!-- include: preserving-usages. path: /fragments/preserving-usages.include.md -->
642+
<!-- include: preserving-usages. path: /fragments/preserving-usages.include.md -->
643+
## Preserving usages of the `[EnumExtensions]` attribute
638644

639645
The `[EnumExtensions]` attribute is decorated with the `[Conditional]` attribute, [so their usage will not appear in the build output of your project](https://andrewlock.net/conditional-compilation-for-ignoring-method-calls-with-the-conditionalattribute/#applying-the-conditional-attribute-to-classes). If you use reflection at runtime on one of your `enum`s, you will not find `[EnumExtensions]` in the list of custom attributes. If you wish to preserve these attributes in the build output, you can define the `NETESCAPADES_ENUMGENERATORS_USAGES` MSBuild variable.
640646

docs/NetEscapades.EnumGenerators.md

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,15 @@ To change this file edit the source file and then run MarkdownSnippets.
2424
* [Why use these packages?](#why-use-these-packages)
2525
* [Adding NetEscapades.EnumGenerators to your project](#adding-netescapadesenumgenerators-to-your-project)
2626
* [Controlling extension accessibility](#controlling-extension-accessibility)
27+
* [Usage Analyzers](#usage-analyzers)
2728
* [Enabling the analyzers](#enabling-the-analyzers)
2829
* [Configuring analyzer severity (optional)](#configuring-analyzer-severity-optional)
2930
* [Code fixes](#code-fixes)
31+
* [Package referencing options](#package-referencing-options)
3032
* [Avoiding runtime dependencies](#avoiding-runtime-dependencies)
3133
* [Choosing the correct packages for your scenario](#choosing-the-correct-packages-for-your-scenario)
32-
* [Enabling automatic interception (experimental)](#enabling-automatic-interception-experimental)<!-- endToc -->
34+
* [Enabling automatic interception (experimental)](#enabling-automatic-interception-experimental)
35+
* [Preserving usages of the `[EnumExtensions]` attribute](#preserving-usages-of-the-enumextensions-attribute)<!-- endToc -->
3336

3437
## Why use these packages?
3538

@@ -344,7 +347,8 @@ or for external enums:
344347
```
345348
<!-- endInclude -->
346349

347-
## Usage Analyzers<!-- include: usage-analyzers. path: /fragments/usage-analyzers.include.md -->
350+
<!-- include: usage-analyzers. path: /fragments/usage-analyzers.include.md -->
351+
## Usage Analyzers
348352

349353
_NetEscapades.EnumGenerators_ includes optional analyzers that encourage the use of the generated extension methods instead of the built-in `System.Enum` methods. These analyzers can help improve performance by suggesting the faster, generated, alternatives like `ToStringFast()`, `HasFlagFast()`, and `TryParse()`.
350354

@@ -414,7 +418,8 @@ All usage analyzers include automatic code fixes. When a diagnostic is triggered
414418

415419
![Demonstrating the code-fix option available in your IDE for each of the analyzers](https://raw.githubusercontent.com/andrewlock/NetEscapades.EnumGenerators/refs/heads/main/docs/images//code_fix.png)<!-- endInclude -->
416420

417-
## Package referencing options<!-- include: package-referencing. path: /fragments/package-referencing.include.md -->
421+
<!-- include: package-referencing. path: /fragments/package-referencing.include.md -->
422+
## Package referencing options
418423

419424
[NetEscapades.EnumGenerators](https://www.nuget.org/packages/NetEscapades.EnumGenerators) is a metapackage that references additional packages for functionality.
420425

@@ -636,7 +641,8 @@ public void CantIntercept()
636641
```
637642
<!-- endInclude -->
638643

639-
## Preserving usages of the `[EnumExtensions]` attribute<!-- include: preserving-usages. path: /fragments/preserving-usages.include.md -->
644+
<!-- include: preserving-usages. path: /fragments/preserving-usages.include.md -->
645+
## Preserving usages of the `[EnumExtensions]` attribute
640646

641647
The `[EnumExtensions]` attribute is decorated with the `[Conditional]` attribute, [so their usage will not appear in the build output of your project](https://andrewlock.net/conditional-compilation-for-ignoring-method-calls-with-the-conditionalattribute/#applying-the-conditional-attribute-to-classes). If you use reflection at runtime on one of your `enum`s, you will not find `[EnumExtensions]` in the list of custom attributes. If you wish to preserve these attributes in the build output, you can define the `NETESCAPADES_ENUMGENERATORS_USAGES` MSBuild variable.
642648

docs/README.md

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,15 @@ To change this file edit the source file and then run MarkdownSnippets.
2424
* [Why use these packages?](#why-use-these-packages)
2525
* [Adding NetEscapades.EnumGenerators to your project](#adding-netescapadesenumgenerators-to-your-project)
2626
* [Controlling extension accessibility](#controlling-extension-accessibility)
27+
* [Usage Analyzers](#usage-analyzers)
2728
* [Enabling the analyzers](#enabling-the-analyzers)
2829
* [Configuring analyzer severity (optional)](#configuring-analyzer-severity-optional)
2930
* [Code fixes](#code-fixes)
31+
* [Package referencing options](#package-referencing-options)
3032
* [Avoiding runtime dependencies](#avoiding-runtime-dependencies)
3133
* [Choosing the correct packages for your scenario](#choosing-the-correct-packages-for-your-scenario)
32-
* [Enabling automatic interception (experimental)](#enabling-automatic-interception-experimental)<!-- endToc -->
34+
* [Enabling automatic interception (experimental)](#enabling-automatic-interception-experimental)
35+
* [Preserving usages of the `[EnumExtensions]` attribute](#preserving-usages-of-the-enumextensions-attribute)<!-- endToc -->
3336

3437
## Why use these packages?
3538

@@ -344,7 +347,8 @@ or for external enums:
344347
```
345348
<!-- endInclude -->
346349

347-
## Usage Analyzers<!-- include: usage-analyzers. path: /fragments/usage-analyzers.include.md -->
350+
<!-- include: usage-analyzers. path: /fragments/usage-analyzers.include.md -->
351+
## Usage Analyzers
348352

349353
_NetEscapades.EnumGenerators_ includes optional analyzers that encourage the use of the generated extension methods instead of the built-in `System.Enum` methods. These analyzers can help improve performance by suggesting the faster, generated, alternatives like `ToStringFast()`, `HasFlagFast()`, and `TryParse()`.
350354

@@ -414,7 +418,8 @@ All usage analyzers include automatic code fixes. When a diagnostic is triggered
414418

415419
![Demonstrating the code-fix option available in your IDE for each of the analyzers](https://raw.githubusercontent.com/andrewlock/NetEscapades.EnumGenerators/refs/heads/main/docs/images//code_fix.png)<!-- endInclude -->
416420

417-
## Package referencing options<!-- include: package-referencing. path: /fragments/package-referencing.include.md -->
421+
<!-- include: package-referencing. path: /fragments/package-referencing.include.md -->
422+
## Package referencing options
418423

419424
[NetEscapades.EnumGenerators](https://www.nuget.org/packages/NetEscapades.EnumGenerators) is a metapackage that references additional packages for functionality.
420425

@@ -636,7 +641,8 @@ public void CantIntercept()
636641
```
637642
<!-- endInclude -->
638643

639-
## Preserving usages of the `[EnumExtensions]` attribute<!-- include: preserving-usages. path: /fragments/preserving-usages.include.md -->
644+
<!-- include: preserving-usages. path: /fragments/preserving-usages.include.md -->
645+
## Preserving usages of the `[EnumExtensions]` attribute
640646

641647
The `[EnumExtensions]` attribute is decorated with the `[Conditional]` attribute, [so their usage will not appear in the build output of your project](https://andrewlock.net/conditional-compilation-for-ignoring-method-calls-with-the-conditionalattribute/#applying-the-conditional-attribute-to-classes). If you use reflection at runtime on one of your `enum`s, you will not find `[EnumExtensions]` in the list of custom attributes. If you wish to preserve these attributes in the build output, you can define the `NETESCAPADES_ENUMGENERATORS_USAGES` MSBuild variable.
642648

docs/fragments/package-referencing.include.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
12
## Package referencing options
23

34
[NetEscapades.EnumGenerators](https://www.nuget.org/packages/NetEscapades.EnumGenerators) is a metapackage that references additional packages for functionality.

docs/fragments/preserving-usages.include.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
12
## Preserving usages of the `[EnumExtensions]` attribute
23

34
The `[EnumExtensions]` attribute is decorated with the `[Conditional]` attribute, [so their usage will not appear in the build output of your project](https://andrewlock.net/conditional-compilation-for-ignoring-method-calls-with-the-conditionalattribute/#applying-the-conditional-attribute-to-classes). If you use reflection at runtime on one of your `enum`s, you will not find `[EnumExtensions]` in the list of custom attributes. If you wish to preserve these attributes in the build output, you can define the `NETESCAPADES_ENUMGENERATORS_USAGES` MSBuild variable.

docs/fragments/usage-analyzers.include.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
12
## Usage Analyzers
23

34
_NetEscapades.EnumGenerators_ includes optional analyzers that encourage the use of the generated extension methods instead of the built-in `System.Enum` methods. These analyzers can help improve performance by suggesting the faster, generated, alternatives like `ToStringFast()`, `HasFlagFast()`, and `TryParse()`.

0 commit comments

Comments
 (0)