jquery / contribute.jquery.org

Developer documentation common to jQuery projects
https://contribute.jquery.org
Other
25 stars 76 forks source link

Don't require spaces inside expression parentheses #134

Open gibson042 opened 8 years ago

gibson042 commented 8 years ago

Excluding spaces from inside expression parentheses, especially in loop-statement assignments, has historically been common in jQuery—and used intentionally to visually distinguish expression parentheses from statement parentheses—but was prohibited by https://github.com/jscs-dev/node-jscs/commit/0f78baf08fba75aeba4575608aaa08c384875701 in response to #104 (which was removing our complicated function-call exceptions).

Since that time, JSCS has added an ignoreParenthesizedExpression option to requireSpacesInsideParentheses. We should adopt it and update the style guide accordingly.

kborchers commented 8 years ago

:+1: for what it's worth from someone who rarely gets to write code anymore :smile:

dmethvin commented 8 years ago

I'm strongly for this as well. cm87kwq