Description
Q | A |
---|---|
Bug report? | no |
Feature request? | yes |
BC Break report? | yes |
RFC? | yes |
Symfony version | 3.4 |
After having upgraded several apps to Symfony Flex (both small and complex apps) the worst thing to me was the overriding of third-party elements. Templates for example where in app/Resources/AcmeBundle/views/
and now should be in src/Resources/AcmeBundle/views/...
, etc.
I asked around in the Symfony Slack chat and the first responses confirmed that bundle inheritance is rarely used, except to customize some templates:
Do you use that in your real projects? Do you override controllers, templates, etc. from third-party bundles?
-> Rarely, but it has happened
-> I've seen that in ApiPlatform, people override the swagger html twig file
-> Apart error pages from twig, I almost never override resources from third-party bundle
-> I overrode ~70% of FosUserBundle, but without bundle inheritance
-> Only the error pages from twig.
-> Me too, only error pages (on real projects)
-> I used it along time ago for RollerworksMultiUserBundle. but that project is EOL (for good!)
-> I only override templates and assets withinapp/Resources/
. Never did any overriding using an inheriting bundle.
Deprecating this feature in 3.4 and removing it in 4.0 is our last chance in several years to do that.
If you agree, we should provide simple alternatives to override all that is listed in this article: How to Override any Part of a Bundle
- templates
- routing
- controllers
- services
- configuration
- entities
- forms
- validation
- translation