divad12/dotfiles — comment on commit 238bedee11a054255043ee873ec6d9e68d26424c
File: .vim/ftplugin/javascript.vim line 1
By divad12:

Here's [another wtf](http://docs.jquery.com/JQuery_Core_Style_Guidelines#Function_Calls):

>Always include extra spaces around the arguments.

foo( true );

> Exception: foo(true) (no spaces) is allowed if you're already inside of another function call.

foo( bar(true) );

> Exception: Functions, object literals, array literals and string literals go snug to front and back of the parentheses - but ONLY when it's the only argument.

foo(function() { });
foo({ });
foo([ ]);
foo(" ");

> Exception: Multi-line function/object/array literals go snug at end (and at start ONLY if the only argument).

WRONG:
foo( true, { blah: "baz" });

RIGHT:
foo( true, {
blah: "baz"
});

Seems to place more cognitive load than style guides are supposed to reduce. (Fortunately we've decided to conform to our own modified version of the style guideline, without these insanities.)