-
From the manual, I see that it should be possible to specify custom variables that Pandoc will then interpolate at given locations in the text. When I try to define one in a markdown document's YAML header like
and then reference this variable in the text with, per the examples in the manual,
the first renders as math, and the last three render just as the text written in the markdown document. The information I'm passing to Pandoc to convert markdown to DOCX is below. Any suggestions for how I can set this working would be most welcome. Thanks so much!
|
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 7 replies
-
The documentation on interpolated variables is in the Template Syntax section. Variable interpolation is done in templates, not in the text. If you want to do something like this in the text, you'll need to use a filter, like this example. |
Beta Was this translation helpful? Give feedback.
-
@fiapps, thank you so much. I now have a custom export in Zettlr that's doing the interpolation properly:
But
Thanks so much! |
Beta Was this translation helpful? Give feedback.
-
▶︎ echo $(basename -s .md in.md).docx
in.docx |
Beta Was this translation helpful? Give feedback.
-
Thanks so much. I'll bear this in mind.
It's quite possible I was doing something amiss here, but I wasn't able to get this to work. Instead, what I was able to get working was the following:
Thanks so much for the help! |
Beta Was this translation helpful? Give feedback.
The documentation on interpolated variables is in the Template Syntax section. Variable interpolation is done in templates, not in the text. If you want to do something like this in the text, you'll need to use a filter, like this example.