You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With #24179 the default_path configuration key was added. Part of this was to allow bundle overrides in /templates/<BundleName>. However, this doesn't appear to be working for Form templates.
Specifically templates in templates/bundles/BundleName/Form/something.html.twig does not override the original. In my case this is for https://github.com/excelwebzone/EWZRecaptchaBundle but I'm guessing this would apply to any Form templates.
The text was updated successfully, but these errors were encountered:
This looks like the referenced bundle use Templating Component and its corresponding syntax to configure the form theme template EWZRecaptchaBundle:Form:ewz_recaptcha_widget.html.twig, which is not compatible with the overriding mechanism of Twig (i.e they are different templates loaders).
In that case you must put your custom template in app/Resources/EWZRecaptchaBundle/views/Form/ewz_recaptcha_widget.html.twig (http://symfony.com/doc/3.4/templating/overriding.html). To use the modern way (templates/bundles/...) the bundle should configure it by using the Twig's syntax instead: @EWZRecaptcha\Form\ewz_recaptcha_widget.html.twig.
Aah gotcha. I completely forgot about the format differences in the template name. That would definitely explain it. I'll go ahead and close this issue.
I had resolved it already by using src/Resources/EWZRecaptchaBundle/views, so at least that works.
With #24179 the
default_path
configuration key was added. Part of this was to allow bundle overrides in/templates/<BundleName>
. However, this doesn't appear to be working for Form templates.Specifically templates in
templates/bundles/BundleName/Form/something.html.twig
does not override the original. In my case this is for https://github.com/excelwebzone/EWZRecaptchaBundle but I'm guessing this would apply to any Form templates.The text was updated successfully, but these errors were encountered: