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

Imagine you have a ‘style czar’ for your language, telling everyone what ‘idiomatic’ code looks like in their language. What do you do when, one release, they go completely crazy?

Or what if an apostate arises and promulgates a radically different vision of what ‘good style’ is in the language?

This isn’t a purely theoretical risk. The ‘Automatic Semicolon Insertion’ heresy is an active alternate reality in the JavaScript world - with some developers willing to argue to the death that semicolon-free style is the only professional way to write JavaScript code; while many developers carry on coding in the C-like syntax JavaScript was clearly intended to use blissfully unaware that they are actually on one side of a violent debate.




That's why its helpful to have an czar or authority to consider opinions and state a preference. To converge the community and stop wasting time on these debates.

Also, nobody has to follow the guidance of 'style czar'. Each team and community could deviate in whatever ways. "We follow the standards expect for these changes about semi-colons." I think just having a standard can helpful when having your own style as well, because you can contrast it against something concrete.


Rubocop in Ruby has the great trailing commas in hash literals debate.

That is what has solidly convinced me that programming languages themselves, like the compiler, absolutely need to fuck off with the rigid style proscriptions.

There does need to be a solid, configurable linter so that any given codebase can have its own strongly held and automatically corrected opinions. I don't trust any one person or a cabal to determine style for everyone using the language though.

When it comes to something like that Javascript semicolon debate, the way to solve it is linters with a flag for either set of people, so they can be their own dictators over their own codebase.


If that happens, you fire them?




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

Search: