docs: record Symfony tooling conventions in CLAUDE.md (#81)#82
Merged
martinyde merged 2 commits intoJun 22, 2026
Merged
Conversation
…nent, Maker Bundle) Adds three subsections to the `Coding practices` section of CLAUDE.md: - Install new dependencies via Symfony Flex (`task composer -- require`) so the recipe wires the bundle, config, and `.env` placeholders. - Prefer `symfony/ux-twig-component` for new template markup. Scan `templates/components/` for an existing component before adding a new one — extending props beats near-duplicates that drift in styling. - Use Maker Bundle (`task console -- make:<thing>`) for scaffolding work when a recipe exists, so generated code stays in step with the attribute-driven idioms already in the codebase. Builds on PR #74 (#74 introduces the `Coding practices` section); this PR sits on top of that branch and should be rebased onto develop once #74 lands. Fixes #81. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…e-md-symfony-practices
tuj
approved these changes
Jun 22, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Links to issues
Fixes #81.
Description
Extends the
Coding practicessection (introduced by PR #74) withthree subsections that name the Symfony-native tooling the project
expects agents to reach for first. Each entry is short and
prescriptive — name the tool, when to reach for it, what failure
mode it prevents.
Added subsections, inserted between
Defer to symfony.com/doc when implementing Symfony featuresandControllers stay thin:task composer -- require <package>so the recipe wiresconfig/bundles.php,config/packages/, and.envplaceholders.Hand-editing
composer.jsonor running composer with--no-scriptsis the failure mode this rule prevents.symfony/ux-twig-component. New reusable markup lives attemplates/components/<Family>/<Name>.html.twigand is invoked via<twig:Family:Name … />, not{% include %}or hand-rolledpartials. Scan the existing families first — extending a component
with a new prop almost always beats a near-duplicate that drifts in
styling.
(entity, controller, command, form, fixture, voter, event
subscriber, registration form, etc.) goes through
task console -- make:<thing>. Hand-rolling boilerplate is thefailure mode this rule prevents.
Verified locally:
symfony/flex,symfony/ux-twig-component, andsymfony/maker-bundleare all already in
composer.json, so each rule names tooling theproject actually has.
task coding-standards-markdown-check— green.Screenshot of the result
n/a — docs-only.
Checklist
Additional comments or questions
do-not-mergerationale: this PR is stacked on top of #74. Baseis
chore/test-method-comments(the head of #74) rather thandevelop. Merge order is #74 first, then this PR, after aquick rebase onto
develop. Remove thedo-not-mergelabel once #74has landed.
Details - AI specificities
Defer to symfony.com/docandControllers stay thinso the"where to find guidance → what tooling to reach for → how to shape
the code" flow reads top-to-bottom.
symfony.com/docrule above ("matches whatsymfony.com/docruleabove points at"), so the two stay aligned conceptually.
(
symfony/flex,symfony/ux-twig-component,symfony/maker-bundle)— none of them imply a new dependency.