3 ms·
To this point: Markdown is a nice format for ingest because you can just paste in HTML. I am a bit more courageous and have some custom directives for my Markdo
by rtpg 4y ago
To this point: Markdown is a nice format for ingest because you can just paste in HTML. I am a bit more courageous and have some custom directives for my Markdown stuff, but it's all really 20 lines of code.
I think it's tempting to add a bunch of "time saving" features for writing, but lots of time just going with the HTML is fine. Maybe if you're writing out a post every couple of days then you can focus on time saves. Until then MD will get you most of the way, and otherwise you can always hack in some special case for your unique post
- chrismorgan 4y agoMarkdown is lousy in significant part because its interactions with HTML are ridiculously complex and moderately difficult to learn, and almost no one tries to actively learn Markdown in a principled fashion, and even fewer try teaching it in a principled fashion, so it ends up unreliable and fairly unpredictable to almost everyone. Things like: if you start a “paragraph” (of which “what comes after a blank line” is a fair approximation) with a block HTML element (e.g. <p>, <div>), inline Markdown syntax won’t work until you start a new “paragraph”. This is related to what I find to be the real killer for just pasting HTML: if you use blank lines followed by lines that are either indented (by at least four spaces or a tab) or don’t start with a block HTML element, then Markdown will mangle your input fiercely. And that’s extremely common (it’s basically recommended formatting for various content). <aside> Markdown syntax is *not* interpreted here, and this is a text node inside an aside. </aside> —⁂— <aside> <p>Markdown syntax is *not* interpreted here, and this is a text node inside a p inside an aside.</p> </aside> —⁂— <aside> Markdown syntax *is* interpreted here, and `aside > p > em` should match. </aside> —⁂— <aside> <p>Markdown syntax is *not* interpreted here, and this is a text node inside a p inside an aside.</p> </aside> —⁂— <aside> <p>This line is a code block (pre) inside an aside.</p> </aside> —⁂— And all that is without taking into account variations in Markdown flavours, and what may happen with unprincipled and inconsistent extension of Markdown. All up, I say if you want sanity that will last, go HTML and avoid Markdown strenuously for anything beyond simple prose.
- rtpg 4y agoI think here you are also somewhat proving the point because you can "go HTML", since the problem is more about markdown not kicking in. I'm mostly kidding but since we are talking about "blogs" (mostly pictures and text) it's OK for there to be a bit of jank. Remember, this is a script for you! You do not have to justify the jank to anyone! Seriously though, I think that what you're describing is a real failing of Markdown. I wanted at one point to use Restructured Text but really you want Sphinx and Sphinx is not meant to be used as a library unfortunately.
- chrismorgan 4y agoThe problem is that part of the time it won’t kick in when you want it to, and part of the time it will kick in when you don’t want it to. I’ve seen plenty of examples of both. I have a well-established track record of disliking Markdown because of how grossly technically unsound it is. I’m steadily designing a more principled replacement for at least my own use, drawing most significantly from reStructuredText, AsciiDoc and Markdown.