4 ms·
Hm, I didn't know the MarkDown-Syntax and I must say that it really is totally unintuitive to have put 2 spaces at the end of a line to get a linebreak. That's
by JustAGeek 17y ago
Hm, I didn't know the MarkDown-Syntax and I must say that it really is totally unintuitive to have put 2 spaces at the end of a line to get a linebreak.
That's just not what one would think having to do.
Ok, so there is the preview but I must admit that I would probably think that the preview is broken, if such a simple thing such as line breaks aren't displayed correctly.
I've encountered so many broken things in web apps that I'd simply assume that this preview is broken, too.
It wouldn't occur to me that there is a special syntax for something as simple as a line break.
- ErrantX 17y ago> I must say that it really is totally unintuitive to have put 2 spaces at the end of a line to get a linebreak Agreed! One way I get round that is to run text through a Markdown parser first then do a regex to replace \n with <br /> That seems to work fairly will ~99% of the time. (I do like Markdown though - compared to, for example, BBCode. It degrades fairly gracefully, ignoring the line break issue, so you can just write a chunk of text and it looks good but formatting is fairly easy to pick up and eventually intuitive for more advanced users)
- monos 17y agothe problem with replacing backslash with <br/> is that there are also the kind of users that make to much carriage returns whenever they feel a sentence is finished. this turns out to be just as ugly. how do you get to the 99%?? i would say there are more people pressing ENTER when they really want a line-wrap then people writing textwalls.
- ErrantX 17y agoUmm well I was respondign to the guy above me with references to the 2 spaces to get a line break problem. Markdown does not parse \n (at least not so I have seen) at all. The textwalls problem I don't have a solution too :)
- pwmanagerdied 17y agoIf you separate text by two line breaks it will be broken into paragraphs, which is how the text looks. Line breaks are only supposed to be used when you don't want a paragraph break, which is at least somewhat uncommon. I'm not saying that it's at all well-explained on the site, but there is at least a reason behind it.