This convo reminds me of MDX -- https://mdxjs.com/ -- allows you to mix JSX with markdown, popular for making documentation pages for design systems.
A lot of the limitations of MD mentioned here are alleviated by allowing arbitrary JSX, which of course is optional for users who want something more basic.