This documentation is also published as Markdown for efficient machine reading: the whole site is indexed at /llms.txt, and every page has a clean Markdown copy under /_llms/. These are generated from the same source and cost far fewer tokens to read than this rendered HTML.

Skip to main content Skip to navigation

CanonicalBaseUrl Pennington.Routing

Singleton wrapper for the site's effective canonical base URL, used by generators (sitemap, RSS, llms.txt) to produce absolute links. Resolved from PenningtonOptions.CanonicalBaseUrl when set, otherwise from OutputOptions.BaseUrl.

Properties

Value UrlPath
The underlying canonical base (an origin like https://site.com, or a path like / or /sub/).

Constructors

CanonicalBaseUrl

#
public CanonicalBaseUrl(UrlPath Value)

Singleton wrapper for the site's effective canonical base URL, used by generators (sitemap, RSS, llms.txt) to produce absolute links. Resolved from PenningtonOptions.CanonicalBaseUrl when set, otherwise from OutputOptions.BaseUrl.

Parameters

Value UrlPath
The underlying canonical base (an origin like https://site.com, or a path like / or /sub/).

Methods

Combine

#
public UrlPath Combine(UrlPath relative)

Combines the base with a site-relative path; see Combine.

Parameters

relative UrlPath

Returns

UrlPath

Pennington.Routing.CanonicalBaseUrl

namespace Pennington.Routing;

/// Singleton wrapper for the site's effective canonical base URL, used by generators (sitemap, RSS, llms.txt) to produce absolute links. Resolved from PenningtonOptions.CanonicalBaseUrl when set, otherwise from OutputOptions.BaseUrl.
public record CanonicalBaseUrl
{
    /// Singleton wrapper for the site's effective canonical base URL, used by generators (sitemap, RSS, llms.txt) to produce absolute links. Resolved from PenningtonOptions.CanonicalBaseUrl when set, otherwise from OutputOptions.BaseUrl.
    
public CanonicalBaseUrl(UrlPath Value)
; /// Combines the base with a site-relative path; see Combine.
public UrlPath Combine(UrlPath relative)
; /// The underlying canonical base (an origin like https://site.com, or a path like / or /sub/).
public UrlPath Value { get; set; }
}