MarkdownAddressingStrategy.EncodeFragmentIdentifier Method

Namespace
Kampute.DocToolkit.Routing
Assembly
  • Kampute.DocToolkit.dll

Definition

Converts the text of a heading to the fragment identifier that addresses the heading.
protected virtual string EncodeFragmentIdentifier(string heading)

Parameters

heading string
The text of the heading.

Returns

string
The fragment identifier for the specified heading, without the leading '#'.

Remarks

The default implementation generates the heading anchor the way GitHub and GitLab do, as described by Markdown.ToHeadingAnchor(string).