aboutsummaryrefslogtreecommitdiff
path: root/pandoc-lua-engine/src/Text/Pandoc/Lua/Module/Format.hs
diff options
context:
space:
mode:
authorAlbert Krewinkel <[email protected]>2022-10-07 21:37:57 +0200
committerJohn MacFarlane <[email protected]>2022-10-10 09:39:18 -0700
commita088cbf5637596a461ba9f99b49210235d6c0a68 (patch)
treed4703d158cf07e4dd45b96fff16166d5ea9abf31 /pandoc-lua-engine/src/Text/Pandoc/Lua/Module/Format.hs
parente1e07cce65a0bb007da934245e74be1b1c8a0f6e (diff)
Lua: support extensions in custom writers
Custom writers can define the extensions that they support via the global `writer_extensions`. The variable's value must be a table with all supported extensions as keys, and their default status as values. E.g., the below specifies that the writer support the extensions `smart` and `sourcepos`, but only the `smart` extension is enabled by default: writer_extensions = { smart = true, sourcepos = false, }
Diffstat (limited to 'pandoc-lua-engine/src/Text/Pandoc/Lua/Module/Format.hs')
-rw-r--r--pandoc-lua-engine/src/Text/Pandoc/Lua/Module/Format.hs5
1 files changed, 2 insertions, 3 deletions
diff --git a/pandoc-lua-engine/src/Text/Pandoc/Lua/Module/Format.hs b/pandoc-lua-engine/src/Text/Pandoc/Lua/Module/Format.hs
index 7eb66b3ca..d9d413e09 100644
--- a/pandoc-lua-engine/src/Text/Pandoc/Lua/Module/Format.hs
+++ b/pandoc-lua-engine/src/Text/Pandoc/Lua/Module/Format.hs
@@ -13,9 +13,8 @@ module Text.Pandoc.Lua.Module.Format
import HsLua
import Text.Pandoc.Error (PandocError)
-import Text.Pandoc.Extensions
- ( getAllExtensions, getDefaultExtensions )
-import Text.Pandoc.Lua.Marshal.Extensions (pushExtensions)
+import Text.Pandoc.Extensions (getAllExtensions, getDefaultExtensions)
+import Text.Pandoc.Lua.Marshal.Format (pushExtensions)
import Text.Pandoc.Lua.PandocLua ()
import qualified Data.Text as T