| 40 columns | |
| >>> Unsplit. |
| function ( first : 123 , second : 345 ) ; |
| <<< |
| function(first: 123, second: 345); |
| >>> Split arguments and add trailing comma. |
| function ( one: "value" , two: "data" , three: "more stuff" ) ; |
| <<< |
| function( |
| one: "value", |
| two: "data", |
| three: "more stuff", |
| ); |
| >>> Mixed named and positional. |
| f(one: 1, "pos", two: 2, "itional"); |
| <<< |
| f(one: 1, "pos", two: 2, "itional"); |
| >>> Mixed named and positional split. |
| function(one: 1, "pos", two: 2, "itional"); |
| <<< |
| function( |
| one: 1, |
| "pos", |
| two: 2, |
| "itional", |
| ); |
| >>> Split after argument name. |
| function(veryLongParameterName: veryLong + argument + expression); |
| <<< |
| function( |
| veryLongParameterName: |
| veryLong + argument + expression, |
| ); |
| >>> Use block-like formatting for arguments that are delimited expressions. |
| function(list: [element1, element2, element3, element4], |
| map: {entry1: valueOne, entry2: valueTwo}, |
| call: function(argument1, argument2, argument3)); |
| <<< |
| function( |
| list: [ |
| element1, |
| element2, |
| element3, |
| element4, |
| ], |
| map: { |
| entry1: valueOne, |
| entry2: valueTwo, |
| }, |
| call: function( |
| argument1, |
| argument2, |
| argument3, |
| ), |
| ); |