Subject: Not exactly
Author:
Posted on: 2022-07-05 15:29:34 UTC

What I mean is that when formatting plain-text documents, it's common for people to word-wrap by hand (well, they use automated tools usually, but the wrapping is physically present in the file). As a result, Markdown doesn't interpret a single newline as a break because that would break on people's text documents (Markdowns is very commonly used on things like READMEs, which tend to do this...).

I'm not sure if it's feasible to alter the markdown parser to interpret a single newline as <br>, because we don't actually handle that directly: we're using redcarpet, which is written by other people. And while it is customizable, I don't yet know how easy or hard it would be to make that change.

While I was researching this, however, I did come across a way to actually get a linebreak in markdown without resorting to HTML tags: turns out, if you end a line with
two
or
more
spaces (that is, " "),
a linebreak will be inserted for you.

Reply Return to messages