-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ios_platform_images] Adopt code-excerpts #5682
[ios_platform_images] Adopt code-excerpts #5682
Conversation
Replaces the Dart example code with a code excerpt. Part of flutter/flutter#102679
It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption to this rule, contact "@text-exemption-reviewers" in the #hackers channel in Chat (don't just cc them here, they won't see it! Use Discord!). If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix? Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing. |
test-exempt: code refactor with no semantic change |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
optional nit
} | ||
<?code-excerpt "example/lib/main.dart (Usage)"?> | ||
```dart | ||
// "flutter" is a resource in Assets.xcassets. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we should rename the asset rather than explain the name with a comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What would we name it that wouldn't require an explanation of where the asset lives?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"asset"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
or something more descriptive
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the context of Flutter code, an asset is usually a Flutter asset, which is a similar concept but in Flutter-land (specifically, in pubspec.yaml) rather than Xcode-project-land; that's why there's a comment explaining it precisely. I guess we could name it 'assetFromAssets.xcassets'
, but I think that's harder to read than the comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Whatever you think is best, that's why it's optional :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can't come up with anything that I find clearer than the comment, so I'll land as-is.
@@ -28,17 +28,20 @@ class _MyAppState extends State<MyApp> { | |||
|
|||
@override | |||
Widget build(BuildContext context) { | |||
// #docregion Usage | |||
// "flutter" is a resource in Assets.xcassets. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same
auto label is removed for flutter/packages/5682, due to - The status or check suite Windows_x64 dart_unit_tests_shard_1 master has failed. Please fix the issues identified (or deflake) before re-applying this label. |
flutter/packages@1151191...3f2e16b 2023-12-15 [email protected] Swap some iOS package CODEOWNERS (flutter/packages#5667) 2023-12-14 [email protected] [in_app_purchase_storekit]add storekit configuration to the example app (flutter/packages#5411) 2023-12-14 [email protected] [camera_platform_interface] Adds support for setting the image file format (flutter/packages#5593) 2023-12-14 [email protected] [path_provider_android] Re-enable getExternalStorageDirectories test (flutter/packages#5668) 2023-12-14 [email protected] [go_router] fix(docs): typo in example extra_codec.dart (flutter/packages#5570) 2023-12-14 [email protected] [ios_platform_images] Adopt code-excerpts (flutter/packages#5682) 2023-12-14 [email protected] [camera] Fix typo "intialize" in doc comments (flutter/packages#4949) 2023-12-14 [email protected] Roll Flutter from 11a9cb7 to a51e33a (30 revisions) (flutter/packages#5680) 2023-12-14 [email protected] [two_dimensional_scrollables] Post 3.16 stable tech debt clean up (flutter/packages#5671) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages-flutter-autoroll Please CC [email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Replaces the Dart example code with a code excerpt. Part of flutter/flutter#102679
Replaces the Dart example code with a code excerpt.
Part of flutter/flutter#102679
Pre-launch Checklist
dart format
.)[shared_preferences]
pubspec.yaml
with an appropriate new version according to the pub versioning philosophy, or this PR is exempt from version changes.CHANGELOG.md
to add a description of the change, following repository CHANGELOG style.///
).