Skip to content

Commit edca4da

Browse files
advancinguweaverryan
authored andcommitted
Clarified variable passing in recursive form rendering.
See symfony/symfony#5565
1 parent 1406b34 commit edca4da

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

reference/forms/twig_reference.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,9 @@ or collection of fields, each underlying form row will be rendered.
4949
The second argument to ``form_widget`` is an array of variables. The most
5050
common variable is ``attr``, which is an array of HTML attributes to apply
5151
to the HTML widget. In some cases, certain types also have other template-related
52-
options that can be passed. These are discussed on a type-by-type basis.
52+
options that can be passed. These are discussed on a type-by-type basis. Note
53+
that in case the first argument is a form, all ``variables`` will
54+
only be applied to the form itself and not its children.
5355

5456
form_row(form.name, variables)
5557
------------------------------

0 commit comments

Comments
 (0)