From 6cd0b9f6631d14f66c4b994771dee60ef74b270c Mon Sep 17 00:00:00 2001 From: Mirek Kratochvil Date: Sun, 18 Jun 2023 22:11:01 +0200 Subject: configurable tocs --- FormatOpts.hs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'FormatOpts.hs') diff --git a/FormatOpts.hs b/FormatOpts.hs index 40d02e8..4759f89 100644 --- a/FormatOpts.hs +++ b/FormatOpts.hs @@ -25,3 +25,7 @@ htmlWriteOpts = -- | Default plaintext writing options for Pandoc. plainWriteOpts :: WriterOptions plainWriteOpts = def {writerWrapText = WrapNone} + +-- | Default options for making tables of contents with certain depth. +tocWriteOpts :: Int -> WriterOptions +tocWriteOpts n = def { writerTOCDepth = n} -- cgit v1.2.3