How would I start making a plugin to present/render LaTeX citations in Obsidian as footnotes?

I recently started using LaTeX citations to take of my references, when I then export my Obsidian notes to PDF.

These citations look like \footcite[24]{Smith2020} or \footnote{\cite{citekey}; \cite{citekey2}}.

In LaTeX these get rendered as footnotes, and the citekeys, e.g. Smith2020, gets turned into in-text references, e.g. Smith 2020, 24, for page 24 of a source by Smith from 2020.

I’d like Obsidian to render these as footnotes too, but only in Preview mode, just like Obsidian already renders ^[footnote] as a footnote, with the location in the text then including a number with a link to the footnote at the bottom.

How would I start going about this?

Cheers

I’ve been told I might have to use a MarkdownPostProcessor but I’m not sure how to do that. Any hints?