Skip to content

[mustache_template] Add example app and code excerpts#11315

Closed
saudademjj wants to merge 3 commits intoflutter:mainfrom
saudademjj:saudademjj/mustache-template-example-app
Closed

[mustache_template] Add example app and code excerpts#11315
saudademjj wants to merge 3 commits intoflutter:mainfrom
saudademjj:saudademjj/mustache-template-example-app

Conversation

@saudademjj
Copy link

Adds a runnable example application and migrates all inline README code blocks to the <?code-excerpt?> system for CI validation.

  • Creates example/lib/main.dart demonstrating basic template rendering, nested paths, and lambdas
  • Creates example/lib/readme_excerpts.dart with #docregion markers for all 8 README code examples
  • Modernizes code style: varfinal/const, adds trailing commas, fixes syntax errors in original examples
  • Removes duplicate LambdaRenderBar example that was repeated in the original README
  • Removes mustache_template from temp_exclude_excerpt.yaml

Fixes flutter/flutter#183936

Version-exempt: changes only affect unpublished example app (publish_to: none) and README documentation.

Test-exempt: documentation excerpt migration and example app addition only; all existing tests pass. Covered by "only affects comments or documentation" exemption.

Pre-Review Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the gemini-code-assist bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

Footnotes

  1. Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling. 2

Create a runnable example app and readme_excerpts.dart with #docregion
markers for all README code examples. Migrate inline README code blocks
to the <?code-excerpt?> system for CI validation.

Fixes flutter/flutter#183936
@flutter-dashboard
Copy link

It looks like this pull request may not have tests. Please make sure to add tests or get an explicit test exemption before merging.

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. If you believe this PR qualifies for a test exemption, contact "@test-exemption-reviewer" in the #hackers channel in Discord (don't just cc them here, they won't see it!). The test exemption team is a small volunteer group, so all reviewers should feel empowered to ask for tests, without delegating that responsibility entirely to the test exemption group.

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request adds a runnable example application for the mustache_template package and migrates the code examples in README.md to use the <?code-excerpt?> system for CI validation. The changes also modernize the code style in the examples, fix existing errors in the README snippets, and remove a duplicated example. Overall, these changes improve the documentation and provide a helpful, runnable example for users. I have a couple of suggestions to align the new example code with the Dart style guide.

saudademjj and others added 2 commits March 21, 2026 14:23
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
@saudademjj
Copy link
Author

Closing to resubmit with code quality improvements based on review feedback.

@saudademjj saudademjj closed this Mar 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[mustache_template] No example app

1 participant