▲ | chrismorgan 4 days ago | ||||||||||||||||
If you’re not accustomed to reStructuredText, it looks dreadful. If you saw it in the context of a larger document that used directives for more things, it’d make more sense. Also the author has very bad taste in having used two spaces of indentation. It should have been three, which makes it significantly less ugly:
“.. ”: this block is magic.“image::”: directive, type image. “example.jpg”: directive argument, file name. “:alt: alttext” directive option, named alt, value alttext. Rewritten with a completely different sort of syntax, for fun:
| |||||||||||||||||
▲ | dangus 3 days ago | parent [-] | ||||||||||||||||
Yikes, this explanation does not make it better. You’re telling me the indentation convention is three spaces? And “..” is just your “something cool is about to happen” symbol? I’ve been reading through the documentation more and this thing seems insane. That .. symbol is also used for comments!? “Oh if it’s invalid it’s a comment!” No way to make multi-line comments without another ridiculous indentation. The tables are insane, somehow they implemented something worse than markdown. To make a header you need to make a long line of characters as long as your text for some reason. For being a language that’s supposed to be more powerful than markdown and not so HTML-adjacent it sure depends on whitespace a lot. Like, why do literal blocks need be indented? Why do doctest blocks need to end with a blank line? > The handling of the :: marker is smart: > If it occurs as a paragraph of its own, that paragraph is completely left out of the document. > If it is preceded by whitespace, the marker is removed. > If it is preceded by non-whitespace, the marker is replaced by a single colon. lol, a directive that does 3 entirely unrelated things depending on white space. Genius. | |||||||||||||||||
|