docs: add Dart code examples and wrap all examples in a CodeGroup component for sliver widget documentation#440
Conversation
…ponent for sliver widget documentation.
📝 WalkthroughWalkthroughThis PR standardizes example formatting across three sliver widget documentation files by replacing standalone "Example JSON" sections with unified "Example" sections that wrap both Dart and JSON code snippets within Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 0
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
docs/widgets/sliver_list.mdx (1)
31-111:⚠️ Potential issue | 🟡 MinorInconsistent structure between Dart and JSON examples.
The Dart example shows only the
StacSliverListcomponent (lines 33-57), but the JSON example wraps it in a fullscaffold > customScrollView > sliversstructure (lines 61-109). This differs from the other sliver docs (sliver_fill_remaining.mdxandsliver_grid.mdx) where both Dart and JSON show just the component.Consider aligning the JSON to show only the
sliverListportion for consistency:📝 Suggested JSON (component only)
-{ - "type": "scaffold", - "body": { - "type": "customScrollView", - "slivers": [ - { - "type": "sliverList", - "children": [ +{ + "type": "sliverList", + "children": [ ... - ] - } - ] - } -} + ] +}
Description
add Dart code examples and wrap all examples in a CodeGroup component for sliver widget documentation
Related Issues
Closes #
Type of Change
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.