Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I agree, I am having trouble thinking of a situation where specific line break positions would be important to me in regular text that isn't covered by some other markdown structure such as code blocks or lists.


One word: poetry. Traditional break behaviour (new para) is great between stanzas/verses; not so much between lines. (It's also the primary reason why the <br> tag still exists in HTML.)


If you end a line with two spaces, the line break after it is kept. Not intuitive, sure, but it works.

Perhaps an alternative "profile" could be specified that preserves all line breaks, and sites focused on poetry or song lyrics could use that profile.


That hidden feature is so thoroughly buried that I didn't even know about it until I read your msg - and I've been writing markdown for years. For mainstream users, it might as well not exist.

Thanks, btw :)


Pandoc supports using a backslash at the end of a line to insert a line-break.


Then insert the <br> tag with two spaces at the end of the line.


It's not a matter of there being no work-around. MarkDown is meant to be as much for ease-of-use for the content creator/editor as it is to be a readable alternative text source. And HTML isn't always the desired output, so why should users have to know anything about HTML unless they're creating HTML?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: