diff --git a/composer.json b/composer.json index 8dd503f62a..0d1c0ad1b2 100644 --- a/composer.json +++ b/composer.json @@ -14,7 +14,6 @@ }, { "name": "Twig Team", - "homepage": "https://twig.symfony.com/contributors", "role": "Contributors" }, { diff --git a/doc/api.rst b/doc/api.rst index fe01e59234..983ef1981a 100644 --- a/doc/api.rst +++ b/doc/api.rst @@ -399,7 +399,7 @@ The escaping rules are implemented as follows: {% set text = "Twig
" %} {{ text }} {# will be escaped #} -* Expressions which the result is always a literal or a variable marked safe +* Expressions which the result is a literal or a variable marked safe are never automatically escaped: .. code-block:: twig @@ -407,14 +407,12 @@ The escaping rules are implemented as follows: {{ foo ? "Twig
" : "
Twig" }} {# won't be escaped #} {% set text = "Twig
" %} - {{ foo ? text : "
Twig" }} {# will be escaped #} + {{ true ? text : "
Twig" }} {# will be escaped #} + {{ false ? text : "
Twig" }} {# won't be escaped #} {% set text = "Twig
" %} {{ foo ? text|raw : "
Twig" }} {# won't be escaped #} - {% set text = "Twig
" %} - {{ foo ? text|escape : "
Twig" }} {# the result of the expression won't be escaped #} - * Objects with a ``__toString`` method are converted to strings and escaped. You can mark some classes and/or interfaces as being safe for some strategies via ``EscaperExtension::addSafeClass()``: diff --git a/doc/tests/sameas.rst b/doc/tests/sameas.rst index cd2b1ad260..c09297114b 100644 --- a/doc/tests/sameas.rst +++ b/doc/tests/sameas.rst @@ -2,7 +2,7 @@ =========== ``same as`` checks if a variable is the same as another variable. -This is the equivalent to ``===`` in PHP: +This is equivalent to ``===`` in PHP: .. code-block:: twig