summaryrefslogtreecommitdiffstats
path: root/markup/converter
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2020-01-04 11:28:19 +0100
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2020-01-04 19:46:01 +0100
commita82d2700fcc772aada15d65b8f76913ca23f7404 (patch)
treefa1c09eb1523d7cda303982b5c08661af9a194d6 /markup/converter
parentae816452b171b6b6aabca6a7423ed28a653baaa2 (diff)
markup/goldmark: Make auto IDs GitHub compatible
You can turn off this behaviour: ```toml [markup] [markup.goldmark] [markup.goldmark.parser] autoHeadingIDAsciiOnly = true ``` Note that the `anchorize` now adapts its behaviour depending on the default Markdown handler. Fixes #6616
Diffstat (limited to 'markup/converter')
-rw-r--r--markup/converter/converter.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/markup/converter/converter.go b/markup/converter/converter.go
index a4585bd03..b8a5c92c1 100644
--- a/markup/converter/converter.go
+++ b/markup/converter/converter.go
@@ -87,6 +87,11 @@ type TableOfContentsProvider interface {
TableOfContents() tableofcontents.Root
}
+// AnchorNameSanitizer tells how a converter sanitizes anchor names.
+type AnchorNameSanitizer interface {
+ SanitizeAnchorName(s string) string
+}
+
// Bytes holds a byte slice and implements the Result interface.
type Bytes []byte