Skip to content

Commit 0776cba

Browse files
qdequippejaviereguiluz
authored andcommitted
[Serializer] Documentation for xml empty attribute
1 parent b43a575 commit 0776cba

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

serializer/encoders.rst

+5
Original file line numberDiff line numberDiff line change
@@ -205,11 +205,16 @@ These are the options available on the :ref:`serializer context <serializer-cont
205205
``cdata_wrapping_pattern`` (default: ````/[<>&]/````)
206206
A regular expression pattern to determine if a value should be wrapped
207207
in a CDATA section.
208+
``ignore_empty_attributes`` (default: ``false``)
209+
If set to true, ignores all attributes with empty values in the generated XML
208210

209211
.. versionadded:: 7.1
210212

211213
The ``cdata_wrapping_pattern`` option was introduced in Symfony 7.1.
212214

215+
.. versionadded:: 7.3
216+
217+
The ``ignore_empty_attributes`` option was introduced in Symfony 7.3.
213218

214219
Example with a custom ``context``::
215220

0 commit comments

Comments
 (0)