-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docx writer does not respect yaml toc variable #4645
Comments
Yes, that's due to the fact that the docx writer doesn't use a template. Thus you cannot use metadata to change the writer's behavior. |
I don't understand this explanation. Currently, the docx writer supports the yaml variable |
Ah yes, the docx writer looks up that variable here. So I guess we could do the same thing for
|
I'd love to see consistency here with other writers like latex. It would be nice if a writer would read command line switches already made available as yaml variable. WRT to templates: Okay, that kind of templates were already known to me. As far as I know, the docx writer uses a default reference.docx. But you are right at that point that this reference.docx does not check variables like the latex template does, because it is simply not possible. I already considered panzer. Nevertheless, it is a bit confusing, if one writer supports a yaml variable and its corresponding command line switch, but another only the command line switch. |
Note: the following produces a toc for latex, but not html and docx:
but maybe that's okay... |
But does the following work now: ---
toc: true
--- That would be sufficient. |
@tolot27 yes it does (current nightly build) |
The following markdown snippet does not produce a docx with a TOC but a PDF with a TOC:
Only after addint
--toc
to the command line of pandoc, a TOC is generated in docx but now also with the title defined in the yaml variabletoc-title
.The text was updated successfully, but these errors were encountered: