Re:Airbnb JavaScript Style Guide
by seniorsassycat on Thursday July 02, 2015 @11:05PM
(#9823189)
I'd like to see the justifications for some of these, particularly 3.5 which I see as only obscuring that the current context is a function.
[ Parent
| on HN ]
Major advantage: fewer characters to type and parse (parse with your eyes, that is).
Major disadvantage: in the short term it might be difficult to parse.
Possible additional major disadvantage: programmers may never adapt and find it difficult to parse for ever more.
Re:Airbnb JavaScript Style Guide
by atinoda-kestrel on Saturday July 04, 2015 @10:24AM
(#9830221)
Yeah, I'm not sold on "fewer characters" as a win. 'cause then we can have the code golf arguments that inevitably get into the nutty realm.
For visual parsing, consistency matters. In an object literal dec I expect:
name : value
That's easy to parse visually. Not good is when suddenly we get: nameandvalue(){
in the space that our brain expects the former.
Re:Airbnb JavaScript Style Guide
by arxpoetica on Thursday July 02, 2015 @11:30PM
(#9823269)
Agreed. That's pretty obscure.