Every now and then, I edit another user's question or answer and encounter something along the lines of the following in the post source:
Help, I need this question solved with these things:<br />
<ul><li>Item1</li><li>Item2</li><li>Item3</li></ul><br />
Can you guys help me with this? Oh and check here also <a href="vagueurl.com">Here</a><br /><br />
Thanks!
Of course, it works, and it renders properly on the question's page... But... it's a real pain to edit and keep the HTML formatting clean and valid. Furthermore users that are not known with HTML and want to edit a post, might have difficulty to do so. For most SU/SO/SF users it probably won't be too big a problem but I can imagine users from Cooking, Photography or any other SE site being like "What the hell is this?"
If you just stick witk MarkDown and at least use its full potential, you'll be using a standard that every user should be able to understand. It will also make the post structure a lot more clear.
For example:
Help, I need this question solved with these things:
- Item1
- Item2
- Item3
Can you guys help me with this? Oh and check here also [Here][4].
Thanks!
[1]: http://vagueurl.com
Honestly, I don't know why some tags are allowed. I understand that not every tag that is allowed has a MarkDown replacement, but tags like the <ul>
, <li>
, <h1/2/3>
and the <br />
should at least be discouraged. We could for example display a warning similar to the "This question seems subjective and will most likely be closed as off-topic" that is shown when certain tags are used.
For example something like the following warning could be shown when the <br />
tag is detected:
You seem to be using the "
<br />
" HTML tag to create a new line. Stack overflow uses MarkDown to format posts, please use a blank line to create a new paragraph or a double space " " to create a new line. For more help, please visit our formatting guide.
So, for the TL;DR people:
Why HTML in posts should be discouraged in my opinion:
- Standardized formatting will make post editing easier and more clear in structure.
- Standardized formatting prevents weird and invalid HTML.
- The MarkDown editor used by SE does not "support"/use HTML formatting to insert images/links.
- I'm not saying HTML usage should be banned, but rather that HTML is discouraged as much as possible.
What do you guys think?