Extending Symfony, Best Practices
summary
Practical checklist for extending Symfony covering two ways to ship bundle configuration (explicit import and prependExtensionConfig so app config can override defaults) with the exact PHP method to call. Shows using service tags for cache clearers and security voters, replacing Twig loaders and the router in a CMS via a compiler pass that injects a runtime config_resolver, and presents working examples (EasyPublish router, Stash-backed cache clearer) while noting pitfalls like early listener instantiation, master vs subrequest issues, and caching untracked files.
AI-written summary · about
