One thing I love about Markdown is that it's possible to write content so that if you follow a few rules, your content can be either converted to (HT)ML and styled needed but still pretty much readable by itself. (And just for myself, I silently add "on a 80-char terminal".)

So when I write/review posts on SO, I try to follow this quite strictly.

One thing bothers me though, are URLs. Most of the time I adhere to referenced URLs, the reference list being indented twith 2 spaces:

[Lorem Ipsum][1] is simply dummy text of the printing and typesetting
industry. Lorem Ipsum has been the industry's standard dummy text ever
since the 1500s, when an unknown printer took a galley of type and
scrambled it to make a type specimen book. 

  [1]: http://www.lipsum.com/

This is nice until the link is long, like some links to SO answers:

If I [override `__getitem__`/`__setitem__`][1], then `get`/`set` don't
work.  How do I make them work?  Surely I don't need to implement them

  [1]: http://stackoverflow.com/questions/2390827/how-to-properly-subclass-dict
  [2]: http://stackoverflow.com/questions/2390827/how-to-properly-subclass-dict
  [3]: http://stackoverflow.com/questions/1622722/overriding-set-methods-in-

Do I have any options how to make the plain-text version less terrible?

  • Regarding Markdown itself, is it possible to safely break the line?

    I don't really believe there is, but it would probably be the only option that would work for non-SO links.

  • Regarding SO links, are there parts that could be stripped?

  • Are there any "internal" SO URL shorteners? (That was a joke. We all really, really, really hate URL shorteners.)

  • 1
    You can strip the title from the link. http://stackoverflow.com/questions/2390827/#2390889 will redirect to the same place as http://stackoverflow.com/questions/2390827/how-to-properly-subclass-dict -and-override-get-set/2390889#2390889 – Hugo Dozois Oct 2 '13 at 15:20
  • When I visit your first example answer and click "share", I get http://stackoverflow.com/a/2390889/474189, which seems quite reasonable to me. – Duncan Jones Oct 2 '13 at 15:21
  • 1
    @DuncanJones And even with that, the second number can be stripped off because it's just your user ID and won't do anything when pasted on the network itself. Makes for a conveniently short URL. – animuson Oct 2 '13 at 15:24
  • @DuncanJones oh, I forgot the "share" links. It's always been puzzling me, though, why there must be two URLs, one that is in your Location bar and different one that is best for sharing. (apart from the "# fragment part") – Alois Mahdal Oct 2 '13 at 15:26

If I visit your first example answer (https://stackoverflow.com/questions/2390827/how-to-properly-subclass-dict-and-override-get-set/2390889#2390889) and click on the "share" button, I get the following URL:


Which seems quite short and convenient to me. The second part is just my user-id, so we can strip that down to:


However, in general I would suggest you don't fret about the look and feel of the source of a question. It's more important that the question looks pleasant when viewed by others.

  • 1
    "I would suggest you don't fret about the look and feel of the source of a question" +1 – hayd Oct 2 '13 at 15:28
  • I would suggest you don't fret about the look and feel of the source of a question From this point such fretting seem unnecessary, but in the end, it's more about semantics than about the looks of the source code. It kind of boils down to the "less is more" principle. For example, why should unnecessarily long link be there/exist in the first place? What if someone copies the link from the HTML version? Why should the link travel around with irrelevant information? – Alois Mahdal Oct 2 '13 at 15:33
  • 2
    SE sites have very nice readable slugs for a reason, @Alois. I don't want to click a link to see what it links to, when I can simply hover to see the URL. Also, shortening the link will make my browser think I didn't visit it yet. So, no: please do NOT use short links when not needed. – Arjan Oct 2 '13 at 15:37
  • I don't want to click a link to see what it links to I'm not fan of obscure links (in fact I hate them, especially if they obscure the host part), I'm fan of unique links. Sure it would be best if the link was something like http://stackoverflow.com/q/how-to-do-blah-blah/a/3 That wouldn't probably avoid collisions, though... – Alois Mahdal Oct 2 '13 at 15:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .