Greg Wilson on Nostr: I now have several applications that use Python's Markdown module to convert Markdown ...
I now have several applications that use Python's Markdown module to convert Markdown to HTML, then immediately parse that HTML with Beautiful Soup so that I have a DOM I can manipulate before generating the final HTML. Is there an option I'm missing somewhere to convert Markdown directly to DOM?
Published at
2024-09-14 17:26:24Event JSON
{
"id": "a774e117d5862257cabd028c04be7cf74b1abc95c0e6241e6e0942c405d75cad",
"pubkey": "85748048d2c797619f163682b12fded90522c2a61c712f01d7b61ec4efc9fdde",
"created_at": 1726334784,
"kind": 1,
"tags": [
[
"proxy",
"https://mastodon.social/@gvwilson/113137076460098021",
"web"
],
[
"proxy",
"https://mastodon.social/users/gvwilson/statuses/113137076460098021",
"activitypub"
],
[
"L",
"pink.momostr"
],
[
"l",
"pink.momostr.activitypub:https://mastodon.social/users/gvwilson/statuses/113137076460098021",
"pink.momostr"
],
[
"-"
]
],
"content": "I now have several applications that use Python's Markdown module to convert Markdown to HTML, then immediately parse that HTML with Beautiful Soup so that I have a DOM I can manipulate before generating the final HTML. Is there an option I'm missing somewhere to convert Markdown directly to DOM?",
"sig": "c2ec60e47d67bd5dfe9153b2f2a2579072abe2f5ca985e09f3710820df2fa977930b514a9e4e1ce3038acca24b360dfdf04a8bf069315be2739758fe07af3322"
}