Skip to content

Commit

Permalink
Merge branch '6.4' into 7.0
Browse files Browse the repository at this point in the history
* 6.4:
  [Serializer] Add documentation about a new XmlEncoder CDATA wrapping opt-out context option
  • Loading branch information
OskarStark committed May 16, 2024
2 parents 99f4ec6 + cb08b46 commit 97bd669
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions components/serializer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1160,8 +1160,16 @@ Option Description
``save_options`` XML saving `options with libxml`_ ``0``
``remove_empty_tags`` If set to true, removes all empty tags in the ``false``
generated XML
``cdata_wrapping`` If set to false, will not wrap any value ``true``
containing one of the following characters (
``<``, ``>``, ``&``) in `a CDATA section`_ like
following: ``<![CDATA[...]]>``
============================== ================================================= ==========================

.. versionadded:: 6.4

Check failure on line 1169 in components/serializer.rst

View workflow job for this annotation

GitHub Actions / Lint (DOCtor-RST)

You are not allowed to use version "6.4". Only major version "7" is allowed.

Check failure on line 1169 in components/serializer.rst

View workflow job for this annotation

GitHub Actions / Lint (DOCtor-RST)

Please only provide ".. versionadded::" if the version is greater/equal "7.0"

The `cdata_wrapping` option was introduced in Symfony 6.4.

Example with custom ``context``::

use Symfony\Component\Serializer\Encoder\XmlEncoder;
Expand Down Expand Up @@ -1881,3 +1889,4 @@ Learn more
.. _`data URI`: https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URIs
.. _seld/jsonlint: https://github.com/Seldaek/jsonlint
.. _$flags: https://www.php.net/manual/en/json.constants.php
.. _`a CDATA section`: https://en.wikipedia.org/wiki/CDATA

0 comments on commit 97bd669

Please sign in to comment.