In the Lord of the Rings fandom there’s a persistent debate whether balrogs, or Durin’s Bane specifically, have wings. The text in Fellowship is ambiguous whether what it is describing are literal wings or something else wing-like.
In the Lord of the Rings fandom there’s a persistent debate whether balrogs, or Durin’s Bane specifically, have wings. The text in Fellowship is ambiguous whether what it is describing are literal wings or something else wing-like.
That’s the beauty of tabs, it can be whatever you want.
But the correct answer is 4
I’m a spaces guy, but agree on the 4. A coder told me decades ago that 4 is better than 2 because if your code starts wrapping due to too many indents you should be refactoring it into functions anyway.
Spaces, in 2026? Why?
In part, because it forces 2-space tab users to confront the indentation issue above
Also there are no drawbacks… I still hit the tab key to indent (and shift tab to dedent). My editor does the rest.
The drawback to spaces is that people with vision issues or dyslexia lose the ability to make the code more readable in their IDE by adjusting tab size.
I can’t speak to dyslexia (but in would guess that 4 spaces is easier than 2?).
At my last job we had a default linter policy of 4 spaces across all languages (python, JS, rust, mostly). We also had a blind coder. He never mentioned it. I’d guess screen readers are capable of dealing with it these days?
You can do the same thing with a linter rule, without forcing everyone to see the code in your preferred way.
That’s just not true.
Enlighten me?
You might want to read this: https://www.reddit.com/r/javascript/comments/c8drjo/nobody_talks_about_the_real_reason_to_use_tabs/
(There are more downsides of spaces, but I do not care to list everything. It should be obvious that “there are no drawbacks” is a far too general statement. :P)
Tabs are one space *quickly runs away*
I use a single space to indent when writing Python in a SecureCRT command window that gets sent to an interactive Python shell on the server.
Run all you want, but we will find you!!! 😉