From 2077739a35fd51ca6f482ce8a108d10799f5b274 Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Wed, 29 Jul 2020 18:13:15 -0700 Subject: Add extensions to `gfm` and `commonmark`: `fenced_code_blocks`, `backtick_code_blocks`, `fenced_code_attributes`. These can't really be disabled in the reader, but they need to be enabled in the writer or we just get indented code. --- src/Text/Pandoc/Extensions.hs | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src') diff --git a/src/Text/Pandoc/Extensions.hs b/src/Text/Pandoc/Extensions.hs index c0a906d1b..430d13401 100644 --- a/src/Text/Pandoc/Extensions.hs +++ b/src/Text/Pandoc/Extensions.hs @@ -253,6 +253,8 @@ githubMarkdownExtensions = extensionsFromList , Ext_strikeout , Ext_task_lists , Ext_emoji + , Ext_fenced_code_blocks + , Ext_backtick_code_blocks ] -- | Extensions to be used with multimarkdown. @@ -362,6 +364,9 @@ getDefaultExtensions "commonmark_x" = extensionsFromList , Ext_raw_attribute , Ext_implicit_header_references , Ext_attributes + , Ext_fenced_code_blocks + , Ext_fenced_code_attributes + , Ext_backtick_code_blocks ] getDefaultExtensions "org" = extensionsFromList [Ext_citations, @@ -484,6 +489,9 @@ getAllExtensions f = universalExtensions <> getAll f , Ext_raw_attribute , Ext_implicit_header_references , Ext_attributes + , Ext_fenced_code_blocks + , Ext_fenced_code_attributes + , Ext_backtick_code_blocks ] getAll "commonmark_x" = getAll "commonmark" getAll "org" = autoIdExtensions <> -- cgit v1.2.3