flutter/dev/benchmarks/platform_channels_benchmarks
Nate 2e748e8598
Implementing control flow collections (#146601)
This pull request aims for improved readability, based on issue #146600.

```dart
// before
Set<Color> _distinctVisibleColors() {
  final Set<Color> distinctVisibleColors = <Color>{};
  if (top.style != BorderStyle.none) {
    distinctVisibleColors.add(top.color);
  }
  if (right.style != BorderStyle.none) {
    distinctVisibleColors.add(right.color);
  }
  if (bottom.style != BorderStyle.none) {
    distinctVisibleColors.add(bottom.color);
  }
  if (left.style != BorderStyle.none) {
    distinctVisibleColors.add(left.color);
  }
  return distinctVisibleColors;
}

// after
Set<Color> _distinctVisibleColors() {
  return <Color>{
    if (top.style != BorderStyle.none) top.color,
    if (right.style != BorderStyle.none) right.color,
    if (bottom.style != BorderStyle.none) bottom.color,
    if (left.style != BorderStyle.none) left.color,
  };
}
```

Most of the repo should be covered in this PR (aside from `flutter_tools/`, since there was a lot going on in there).
2024-04-15 16:06:07 +00:00
..
android/app/src/main/kotlin/com/example/platform_channels_benchmarks Set up Kotlin linting step in ci with ktlint (#143478) 2024-04-03 21:21:00 +00:00
ios Migrate Xcode projects last version checks to Xcode 15.1 (#140256) 2024-01-03 23:05:46 +00:00
lib Implementing control flow collections (#146601) 2024-04-15 16:06:07 +00:00
.metadata Added performance benchmarks for platform channels (#81414) 2021-05-07 10:24:03 -07:00
pubspec.yaml [flutter_tools] Fix conductor for package args roll (#146646) 2024-04-12 21:38:03 +00:00
README.md Added performance benchmarks for platform channels (#81414) 2021-05-07 10:24:03 -07:00

platform_channels_benchmarks

The harness for running performance benchmark tests for Platform Channels.

If you want to run these benchmarks outside of devicelab you need to first run: flutter create --platforms="ios,android" --no-overwrite .