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

HeadTagKey Pennington.Head

Identity used for head deduplication. Two tags with the same key collapse to one — the first contributor to add at a key wins (contributors run lowest-Order first, so page-level beats site-level). Repeatable tags (hreflang, JSON-LD, preloads) opt out by being added with no key via AddRepeatable.

Properties

Value string
Stable string identity (e.g. title, meta:prop:og:image, link:rel:canonical).

Constructors

HeadTagKey

#
public HeadTagKey(string Value)

Identity used for head deduplication. Two tags with the same key collapse to one — the first contributor to add at a key wins (contributors run lowest-Order first, so page-level beats site-level). Repeatable tags (hreflang, JSON-LD, preloads) opt out by being added with no key via AddRepeatable.

Parameters

Value string
Stable string identity (e.g. title, meta:prop:og:image, link:rel:canonical).

Fields

Title HeadTagKey
The singleton document title.

Methods

LinkRel

#
public static HeadTagKey LinkRel(string rel)

Builds the key for a singleton link rel (e.g. link:rel:canonical).

Parameters

rel string

Returns

HeadTagKey

MetaName

#
public static HeadTagKey MetaName(string name)

Builds the key for a named meta tag (e.g. meta:name:description).

Parameters

name string

Returns

HeadTagKey

MetaProperty

#
public static HeadTagKey MetaProperty(string property)

Builds the key for an OpenGraph/property meta tag (e.g. meta:prop:og:image).

Parameters

property string

Returns

HeadTagKey

Pennington.Head.HeadTagKey

namespace Pennington.Head;

/// Identity used for head deduplication. Two tags with the same key collapse to one — the first contributor to add at a key wins (contributors run lowest-Order first, so page-level beats site-level). Repeatable tags (hreflang, JSON-LD, preloads) opt out by being added with no key via AddRepeatable.
public struct HeadTagKey
{
    /// Identity used for head deduplication. Two tags with the same key collapse to one — the first contributor to add at a key wins (contributors run lowest-Order first, so page-level beats site-level). Repeatable tags (hreflang, JSON-LD, preloads) opt out by being added with no key via AddRepeatable.
    
public HeadTagKey(string Value)
; /// Builds the key for a singleton link rel (e.g. link:rel:canonical).
public static HeadTagKey LinkRel(string rel)
; /// Builds the key for a named meta tag (e.g. meta:name:description).
public static HeadTagKey MetaName(string name)
; /// Builds the key for an OpenGraph/property meta tag (e.g. meta:prop:og:image).
public static HeadTagKey MetaProperty(string property)
; /// The singleton document title.
public static readonly HeadTagKey Title
; /// Stable string identity (e.g. title, meta:prop:og:image, link:rel:canonical).
public string Value { get; set; }
}