^t => "    " = ♥

A part of me thinks this is so obvious I shouldn't need to post about it. But I keep seeing "tabs vs spaces" articles by programmers and just...don't...get it.

Modern text editors let you choose in settings how to treat tabs. The significant choices are:

  1. How many spaces a tab represents
  2. Whether to save the tab character in the document or convert it to spaces

To me this has always been easy.

  1. Four spaces
  2. Convert tabs to spaces

When typing, it's faster to indent using the tab key. But when sharing with another person, there's no guarantee their tabs will use the same number of spaces as yours. So fidelity and consistency demand spaces.1

It doesn't matter what efficient keyboard shorcuts you take to generate the spaces, as long as the document ends up with only spaces.

The only argument for storing tabs in the document is being able to back "space" using them. But it's not enough of a timesaver to overcome the advantages of storing spaces.

There is no reasonable--or reason for a--tabs vs spaces debate.


  1. If you never share your work, then the entire question is moot. I don't care what you do.