3 ms·
I generally don't like using tabs, as I find having two characters for whitespace leads to annoying inconsistencies. However, were a team member request I use t
by gopiandcode 7y ago
I generally don't like using tabs, as I find having two characters for whitespace leads to annoying inconsistencies. However, were a team member request I use tabs for accessibility reasons, I would have no issue complying.
That aside, I don't feel that this particular argument any stronger than any personal preference, let alone some kind of be-all final reason.
Generally whenever more than one space is used consecutively it is intended for indentation purposes - thus an equivalent solution to the accessibility problem is to just configure the editor to render consecutive spaces differently.
The post author calls for more editors to support adjusting tab widths showing that using tabs isn't automatically an accessibility win - spaces users could just as easily call for more editors to support custom ligatures to help the visually impaired.
- skohan 7y agoI actually find having a separate character for indentation is a strength of tabs rather than a detriment. Tabs tell you how the lines in your program relate to one another, and spaces tell you how things relate within a given line. On top of that, I think the strongest argument for tabs is efficiency. space-indented code uses 3 times as many bytes to represent a level of indentation than tab-delimited code. That might not seem like a lot, but spread over all the commits in all the codebases using spaces, it seems pointless to use all that extra disk space for no reason. I think the real problem is that the default tab width for web interfaces is 8 spaces. If it were a more reasonable 4 characters wide, I doubt it would even be an issue.
- pseudalopex 7y agoMore than one consecutive space is very frequently used for alignment. Converting on open and save would be simple otherwise. The author calls for more websites to support adjusting tab widths. What editor doesn't?