We did this a decade or two ago when Markdown was Markdown and pug was Jade. It was great.
Apart from that, also back in the day people were still building pages using e.g. Dreamweaver, so we also put together a thing that could leverage a designer's HTML that rendered as a complete placeholder page. That "works as plain .HTML" became the template, used YAML as data, and Enlive (a Clojure lib) to turn the HTML with its placeholders into a template and then stuff YAML sidecar data into it to generate new HTML.
Not long after, Caddy's markdown support had promise, but agree with another commenter here that a few years ago astro.build started hitting a more interesting spot. In the middle ages between those, yay pandoc.
Pug (previously Jade) was a precursor to web frameworks. Technologies we use and enjoy today were built by previous decades of stumbling in the dark with one feature and hammering it into formidable shape. A nod to Handlebars while we're on the topic.
Recently found myself saying in conversations that, "Markdown is arguably one of the most valuable file type we have; media, documents, code blocks of almost any language, ... all in one place for further processing."
└── Dey well; Be well