over_react icon indicating copy to clipboard operation
over_react copied to clipboard

UIP-1639 Update formatting guidelines WRT dartfmt and trailing commas

Open greglittlefield-wf opened this issue 8 years ago • 1 comments

Our formatting guidelines currently recommend against using dartfmt/dart_style on over_react code.

We recently discovered that dartfmt is capable of producing significantly more readable over_react code, due to changes in dart_style that treat Flutter code better when nested components use trailing commas.

For more info, see https://github.com/dart-lang/dart_style/issues/549. Thanks to @skybrian for getting the conversation started, and to @matanlurey for suggesting we revisit the issue!

We should upgrade the formatting guidelines to:

  • recommend trailing commas whenever supplying variadic children to a builder, even if it's just one
  • indicate that dartfmt output, while not perfect, is acceptable when trailing commas are used

FYI: @greglittlefield-wf @aaronlademann-wf @jacehensley-wf @clairesarsam-wf @joelleibow-wf

greglittlefield-wf avatar Nov 02 '16 15:11 greglittlefield-wf

It looks like you have not included any tickets in the title of this issue. Please create a ticket for this issue, or click here to have Rosie create one for you.

rmconsole-wf avatar Nov 02 '16 15:11 rmconsole-wf