diff options
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/internals/deprecation.txt | 2 | ||||
| -rw-r--r-- | docs/ref/templates/builtins.txt | 3 | ||||
| -rw-r--r-- | docs/releases/3.1.txt | 7 |
3 files changed, 11 insertions, 1 deletions
diff --git a/docs/internals/deprecation.txt b/docs/internals/deprecation.txt index 183ce23408..074345ef40 100644 --- a/docs/internals/deprecation.txt +++ b/docs/internals/deprecation.txt @@ -90,6 +90,8 @@ details on these changes. ``django.contrib.postgres.fields.jsonb.KeyTransform``, and ``django.contrib.postgres.fields.jsonb.KeyTextTransform`` will be removed. +* The ``{% ifequal %}`` and ``{% ifnotequal %}`` template tags will be removed. + See the :ref:`Django 3.1 release notes <deprecated-features-3.1>` for more details on these changes. diff --git a/docs/ref/templates/builtins.txt b/docs/ref/templates/builtins.txt index cdb214c830..a8e8ad98f8 100644 --- a/docs/ref/templates/builtins.txt +++ b/docs/ref/templates/builtins.txt @@ -611,10 +611,11 @@ you should use:: ``ifequal`` and ``ifnotequal`` ------------------------------ +.. deprecated:: 3.1 + ``{% ifequal a b %} ... {% endifequal %}`` is an obsolete way to write ``{% if a == b %} ... {% endif %}``. Likewise, ``{% ifnotequal a b %} ... {% endifnotequal %}`` is superseded by ``{% if a != b %} ... {% endif %}``. -The ``ifequal`` and ``ifnotequal`` tags will be deprecated in a future release. .. templatetag:: ifchanged diff --git a/docs/releases/3.1.txt b/docs/releases/3.1.txt index 120a326628..35e46e5650 100644 --- a/docs/releases/3.1.txt +++ b/docs/releases/3.1.txt @@ -812,6 +812,13 @@ Miscellaneous * ``django.conf.urls.url()`` alias of :func:`django.urls.re_path` is deprecated. +* The ``{% ifequal %}`` and ``{% ifnotequal %}`` template tags are deprecated + in favor of :ttag:`{% if %}<if>`. ``{% if %}`` covers all use cases, but if + you need to continue using these tags, they can be extracted from Django to a + module and included as a built-in tag in the :class:`'builtins' + <django.template.backends.django.DjangoTemplates>` option in + :setting:`OPTIONS <TEMPLATES-OPTIONS>`. + .. _removed-features-3.1: Features removed in 3.1 |
