Hacker News new | past | comments | ask | show | jobs | submit login

That's the reason I use tabs for indentation? 4 spaces will render as 4 spaces, 2 as 2.

1 tab will render to whatever the next programmer prefers, it's only courteous.




It's courteous except to those that don't like tabs, so you really can't win.

Many languages have a coding style preference. Go is super opinionated, Python in the middle, with C being as conflicted as it gets. Whatever you use, follow the style the language or team is a proponent of.


Picking one or the other will be slightly discourteous to the other side, in this case this is an advantage only tabs hold.


If you don't like tabs, converting them to spaces is trivial. You could even add git hooks to do it automatically.


If it's your own personal code-base, go nuts. If you're working on a team don't be the one who does this and wrecks every file you touch.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: