15

people who don't use semi colons in JavaScript. I know it's not required but God does it drive me nuts.

also one line if statements that don't use brackets.

ahhhhh

Comments
  • 0
    Guilty but only of semicolons 😶
  • 2
    Certain companies like Google and Apple have or at least have had style guides that ban one line if statements without brackets. I heard in the case of Apple it was due to bugs updating code in spots with one line if statements. I always use brackets just for that reason now.
  • 0
    It's "standard JS". Not its not standard, it's stupid.

    var counter=function(){var n=0;return{get:function(){alert(n)},set:function(t){n=t},increment:function(){alert(++n)}}}();

    is also valid js, but it's stupid.
Add Comment