Skip to content
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

fix: Add stack to avoid_single_child #57

Merged
merged 5 commits into from
Sep 3, 2024

Conversation

boywithdv
Copy link
Contributor

@boywithdv boywithdv commented Sep 3, 2024

🔗 Related Issues

🙌 What's Done

  • Add stack to avoid_single_child

✍️ What's Not Done

🖼️ Image Differences

スクリーンショット 2024-09-03 11 43 59

🤼 Desired Review Method

  • Correction Commit
  • Pair programming

Note

It is possible that a reviewer's will may cause a method to be implemented that is not selected.

📝 Additional Notes

Pre-launch Checklist

  • I have reviewed my own code.
  • I have added tests that prove my fix is effective or that my feature works.
  • I updated/added relevant documentation (doc comments with ///).

@boywithdv boywithdv marked this pull request as ready for review September 3, 2024 02:48
@boywithdv boywithdv requested a review from a team as a code owner September 3, 2024 02:48
@boywithdv boywithdv requested review from riscait and removed request for a team September 3, 2024 02:48
Copy link
Member

@riscait riscait left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Comment on lines 47 to 53
Text('World'),
],
),
// expect_lint: avoid_single_child
SliverList.list(
children: const [
Text('World'),
Text('Hello'),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

badge
Why did you swap these two strings?
Both Hello looks good.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made this change because I believe the text should be alternated, like "Hello" and "World," similar to how you would arrange them in a Column or Row. Specifically, I placed the Stack widget under the Wrap widget, so I wrote "Hello," and since the ListView widget is under the Stack, I decided "World" should be written to alternate the text.

The following commit adds a fix to make both Hello.
a21c8a6

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see, you thought about what would happen if it appeared on the screen!
Please comment why next time.

@boywithdv boywithdv merged commit c2e3ccb into main Sep 3, 2024
1 check passed
@boywithdv boywithdv deleted the 45-avoid-single-child-target-stack-add branch September 3, 2024 06:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Stack to the avoid_single_child target
2 participants