diff options
author | Matthias Andreas Benkard <code@mail.matthias.benkard.de> | 2022-05-02 20:29:56 +0200 |
---|---|---|
committer | Matthias Andreas Benkard <code@mail.matthias.benkard.de> | 2022-05-03 07:37:51 +0200 |
commit | 64bf1091258477f505bf07939007440f86d33254 (patch) | |
tree | 42b35668daadc21655b4f54753aed9b12a710a46 /src/main/java | |
parent | 6fca8dc89c370c7bc0318be956780c5b9f4096d6 (diff) |
MarkdownConverter: Enable FootnoteExtension.
Change-Id: I6c7018edfd4e41e54390c397a3ba675d30ccabc6
Diffstat (limited to 'src/main/java')
-rw-r--r-- | src/main/java/eu/mulk/mulkcms2/common/markdown/MarkdownConverter.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main/java/eu/mulk/mulkcms2/common/markdown/MarkdownConverter.java b/src/main/java/eu/mulk/mulkcms2/common/markdown/MarkdownConverter.java index 0200514..75f6c8d 100644 --- a/src/main/java/eu/mulk/mulkcms2/common/markdown/MarkdownConverter.java +++ b/src/main/java/eu/mulk/mulkcms2/common/markdown/MarkdownConverter.java @@ -3,6 +3,7 @@ package eu.mulk.mulkcms2.common.markdown; import com.vladsch.flexmark.ext.abbreviation.AbbreviationExtension; import com.vladsch.flexmark.ext.autolink.AutolinkExtension; import com.vladsch.flexmark.ext.definition.DefinitionExtension; +import com.vladsch.flexmark.ext.footnotes.FootnoteExtension; import com.vladsch.flexmark.ext.gfm.strikethrough.StrikethroughExtension; import com.vladsch.flexmark.ext.tables.TablesExtension; import com.vladsch.flexmark.ext.typographic.TypographicExtension; @@ -30,12 +31,14 @@ public class MarkdownConverter { AbbreviationExtension.create(), AutolinkExtension.create(), DefinitionExtension.create(), - TypographicExtension.create())); + TypographicExtension.create(), + FootnoteExtension.create())); options.set(Parser.FENCED_CODE_BLOCK_PARSER, true); options.set(HtmlRenderer.SOFT_BREAK, "\n"); options.set(HtmlRenderer.HARD_BREAK, "<br />\n"); options.set(TypographicExtension.ENABLE_SMARTS, true); options.set(TypographicExtension.ENABLE_QUOTES, true); + options.set(FootnoteExtension.FOOTNOTE_BACK_REF_STRING, ""); this.parser = Parser.builder(options).build(); this.renderer = HtmlRenderer.builder(options).build(); |