Closed rbdixon closed 8 years ago
Hmmm.... I'd never considered that there was a template for generating markdown!
https://github.com/jgm/pandoc-templates/blob/master/default.markdown shows:
$if(titleblock)$
$titleblock$
$endif$
$for(header-includes)$
$header-includes$
$endfor$
$for(include-before)$
$include-before$
$endfor$
$if(toc)$
$toc$
$endif$
$body$
$for(include-after)$
$include-after$
$endfor$
If there is a toc
variable, then show it. Not a bug, closing. Sorry. :)
When building my markdown document I observed a spurious "true" at the start of the document. I whittled the document down till I found this minimal example:
x.yml
has a keyx
set to true and works as I would expect it.toc.yml
has a keytoc
set to true and demonstrates a surprising behavior. Why is that "true" in the document output?I'm aware that
toc
is a variable set by pandoc based on the --toc command line parameter. I was attempting to make the table of contents generation controllable by insertingtoc: true
in a YAML metadata block. If that's not a good idea let me know... but I still was not expectingtrue
to pop up in the document output. Seems like a bug.All files and pandoc version details: https://gist.github.com/rbdixon/9885f6bad6584b52196d