Bob Nystrom
Bob Nystrom
Thank you for the feedback! Re: ```dart child: Column(children: [Text('Hello'), Text('Dart'), Text('World')]), ``` Yeah, that looks like a bug in the prototype. I wouldn't expect it to split after a...
> Could this also account for pattern-matching formatting? Yeah, there's probably some tweaks needed there to harmonize with the proposal. Thanks for bringing that example up. :)
> Also, since [this](https://github.com/munificent/format-sample/commit/b2d08f533752cdb50f0e6a3330a93a63d4d9cf0b#diff-e707a2e95ee75bd2656490b095f66411f083bc8fe655005f67199a986defe5c3L298-L303) extra indentation of 2 levels goes completely against the grain, I'm guessing it wasn't intentional? > > ```diff > placeholder: (context, url) => Center( > -...
> 1. Do I understand correctly that the formatter will actually add/remove commas (and not just format as if they were there)? Yes. > Will this functionality be opt-in (either...
> But for map literals, perhaps the rules could be tweaked to prefer "tall" style more often? For example, force “tall” style if a map has more than 2 or...
This is mostly a consequence of the weird interaction between how trailing commas affect formatting and the formatting rules around lambdas in argument lists. If you remove the trailing commas,...
With the [forthcoming](https://github.com/dart-lang/dart_style/issues/1403) [tall style](https://github.com/dart-lang/dart_style/issues/1253), it looks like: ```dart void onLink(DynamicLinkEvent event) { var link = event.data?.link?.toString(); if (link != null && _firebaseAuth.isSignInWithEmailLink(link)) { var url = Uri.parse(event.data.link.queryParameters['continueUrl']); var email...
> I hope this is still going to be a valid solution after the suggested change in this proposal. It will, yes.
> Is it on purpose or because of some rules on closures? It's a consequence of the general rule that the body of a function declaration using `=>` is indented...
I think it's unlikely. Nested functions are a difficult corner of the formatter's rules and it's hard to change how they are handled without producing worse output in other cases....