-
Notifications
You must be signed in to change notification settings - Fork 18
Open
Labels
enhancementNew feature or requestNew feature or requestwrappingIncorrect or undesirable wrappingIncorrect or undesirable wrapping
Description
Since trailing commas are implemented in most places, we can utilize it in formatter as style option like this:
function name(a:Int, b:Int):Void {} // format with default wrapping style from config
function name(
a:Int,
b:Int, // reformat with `onePerLine` when there is trailing comma
):Void {}Same can be applied for function calls and arrays:
foo("abc");
foo(
"abc",
);
final arr = ["banana", "orange"];
final arr = [
"banana",
"orange",
];I think this also can be useful as default behavior to open more customization without touching line length rules and stuff.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestwrappingIncorrect or undesirable wrappingIncorrect or undesirable wrapping