diff options
author | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2020-01-04 11:28:19 +0100 |
---|---|---|
committer | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2020-01-04 19:46:01 +0100 |
commit | a82d2700fcc772aada15d65b8f76913ca23f7404 (patch) | |
tree | fa1c09eb1523d7cda303982b5c08661af9a194d6 /markup/goldmark/goldmark_config/config.go | |
parent | ae816452b171b6b6aabca6a7423ed28a653baaa2 (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/goldmark/goldmark_config/config.go')
-rw-r--r-- | markup/goldmark/goldmark_config/config.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/markup/goldmark/goldmark_config/config.go b/markup/goldmark/goldmark_config/config.go index bf18a384d..2454eb46f 100644 --- a/markup/goldmark/goldmark_config/config.go +++ b/markup/goldmark/goldmark_config/config.go @@ -69,6 +69,10 @@ type Parser struct { // auto generated heading ids. AutoHeadingID bool + // When AutoHeadingID is enabled this will generate IDs with Ascii + // characters only. + AutoHeadingIDAsciiOnly bool + // Enables custom attributes. Attribute bool } |