My FOSS text editor, KeenWrite[1], takes a similar approach: Markdown -> XHTML -> TeX -> PDF. The software architecture shows how you can have processor chains:
I developed KeenWrite to help write a sci-fi novel where I can use variables for character names, places, etc. See the tutorials[2] for details.
For anyone still using pandoc and shell scripts, my Typesetting Markdown[3] series describes building a script-based infrastructure for converting Markdown into PDF.
https://gitlab.com/DaveJarvis/KeenWrite/-/blob/main/docs/ima...
I developed KeenWrite to help write a sci-fi novel where I can use variables for character names, places, etc. See the tutorials[2] for details.
For anyone still using pandoc and shell scripts, my Typesetting Markdown[3] series describes building a script-based infrastructure for converting Markdown into PDF.
[1]: https://keenwrite.com/
[2]: https://www.youtube.com/watch?v=CFCqe3A5dFg&t=15s
[3]: https://dave.autonoma.ca/blog/2019/05/22/typesetting-markdow...