Style Guide: Context-changing methods as first method call #107
Open
Description
From jquery/jquery-ui#1508 (comment):
We can make the rules for chained method calls a bit more lenient, something like "Context changing method calls at the start of the chain are acceptable on the first line.", along with an example, e.g. the filter/attr chain.
Example:
this.tabs.filter( function() {
return $( this ).attr( "tabIndex" ) === 0;
} )
.attr( "tabIndex", -1 );
Any arguments against this?
Metadata
Assignees
Labels
No labels