Soenneker.Gen.Razor.Sitemaps
4.0.79
Prefix Reserved
dotnet add package Soenneker.Gen.Razor.Sitemaps --version 4.0.79
NuGet\Install-Package Soenneker.Gen.Razor.Sitemaps -Version 4.0.79
<PackageReference Include="Soenneker.Gen.Razor.Sitemaps" Version="4.0.79"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
<PackageVersion Include="Soenneker.Gen.Razor.Sitemaps" Version="4.0.79" />
<PackageReference Include="Soenneker.Gen.Razor.Sitemaps"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
paket add Soenneker.Gen.Razor.Sitemaps --version 4.0.79
#r "nuget: Soenneker.Gen.Razor.Sitemaps, 4.0.79"
#:package Soenneker.Gen.Razor.Sitemaps@4.0.79
#addin nuget:?package=Soenneker.Gen.Razor.Sitemaps&version=4.0.79
#tool nuget:?package=Soenneker.Gen.Razor.Sitemaps&version=4.0.79
Soenneker.Gen.Razor.Sitemaps
Automatic sitemap generation for Razor apps at build time. Fast, deterministic, and zero-runtime overhead.
Installation
dotnet add package Soenneker.Gen.Razor.Sitemaps
Usage
Enable sitemap generation in the app project:
<PropertyGroup>
<RazorSitemapEnabled>true</RazorSitemapEnabled>
<RazorSitemapBaseUrl>https://example.com</RazorSitemapBaseUrl>
<RazorSitemapOutputPath>wwwroot/sitemap.xml</RazorSitemapOutputPath>
<RazorSitemapIncludeUnannotatedPages>true</RazorSitemapIncludeUnannotatedPages>
</PropertyGroup>
Routes are discovered from .razor files with @page. Dynamic routes such as /products/{id} are skipped because they cannot be represented as concrete sitemap URLs.
Optional per-page metadata:
@page "/about"
@using Soenneker.Razor.Sitemap
@attribute [Sitemap(ChangeFrequency = "monthly", Priority = 0.8, LastModified = "2026-04-28")]
Use Exclude = true to omit a page, or Url = "/custom-url" to override the generated route URL. lastmod is emitted for every URL from the .razor file timestamp unless LastModified is set. ChangeFrequency and Priority are supported but omitted by default. The package injects Soenneker.Razor.Sitemap.SitemapAttribute at compile time, so no runtime dependency is required.
Learn more about Target Frameworks and .NET Standard.
-
.NETStandard 2.0
- 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.
| Version | Downloads | Last Updated |
|---|---|---|
| 4.0.79 | 74 | 8/26/2026 |
| 4.0.78 | 45 | 8/26/2026 |
| 4.0.77 | 110 | 8/24/2026 |
| 4.0.76 | 100 | 8/22/2026 |
| 4.0.75 | 80 | 8/22/2026 |
| 4.0.74 | 88 | 8/22/2026 |
| 4.0.73 | 94 | 8/21/2026 |
| 4.0.72 | 269 | 8/18/2026 |
| 4.0.71 | 118 | 8/17/2026 |
| 4.0.70 | 200 | 8/12/2026 |
| 4.0.69 | 106 | 8/12/2026 |
| 4.0.68 | 87 | 8/12/2026 |
| 4.0.67 | 290 | 8/9/2026 |
| 4.0.66 | 157 | 8/8/2026 |
| 4.0.65 | 89 | 8/8/2026 |
| 4.0.64 | 92 | 8/8/2026 |
| 4.0.63 | 266 | 8/7/2026 |
| 4.0.62 | 216 | 7/29/2026 |
| 4.0.61 | 100 | 7/29/2026 |
| 4.0.60 | 101 | 7/29/2026 |