From 3c5c69138c34e749b2560be46414cc2a8fc4a295 Mon Sep 17 00:00:00 2001 From: Matt Westcott Date: Wed, 27 Jul 2016 16:49:23 +0100 Subject: [PATCH] Mention jinja2 include_block tag in 1.6 release notes --- CHANGELOG.txt | 2 +- docs/releases/1.6.rst | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index aa69640d74..bc5582e410 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -5,7 +5,7 @@ Changelog ~~~~~~~~~~~~~~~~ * Django 1.10 support - * Added the ``include_block`` template tag for improved StreamField template inclusion (Matt Westcott) + * Added the ``include_block`` template tag for improved StreamField template inclusion (Matt Westcott, Mikalai Radchuk) * Page slugs now allow unicode on Django >= 1.9 (Behzad Nategh) * Image upload form in image chooser now performs client side validation so that the selected file is not lost in the submission (Jack Paine) * oEmbed URL for audioBoom was updated (Janneke Janssen) diff --git a/docs/releases/1.6.rst b/docs/releases/1.6.rst index a6662896eb..7edc04bdb2 100644 --- a/docs/releases/1.6.rst +++ b/docs/releases/1.6.rst @@ -20,7 +20,7 @@ Wagtail is now compatible with Django 1.10. Thanks to Mikalai Radchuk and Paul J ``{% include_block %}`` tag for improved StreamField template inclusion ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -In previous releases, the standard way of rendering the HTML content of a StreamField was through a simple variable template tag, such as ``{{ page.body }}``. This had the drawback that any templates used in the StreamField rendering would not inherit variables from the parent template's context, such as ``page`` and ``request``. To address this, a new template tag ``{% include_block page.body %}`` has been introduced as the new recommended way of outputting Streamfield content - this replicates the behaviour of Django's ``{% include %}`` tag, passing on the full template context by default. For full documentation, see :ref:`streamfield_template_rendering`. This feature was developed by Matt Westcott. +In previous releases, the standard way of rendering the HTML content of a StreamField was through a simple variable template tag, such as ``{{ page.body }}``. This had the drawback that any templates used in the StreamField rendering would not inherit variables from the parent template's context, such as ``page`` and ``request``. To address this, a new template tag ``{% include_block page.body %}`` has been introduced as the new recommended way of outputting Streamfield content - this replicates the behaviour of Django's ``{% include %}`` tag, passing on the full template context by default. For full documentation, see :ref:`streamfield_template_rendering`. This feature was developed by Matt Westcott, and additionally ported to Jinja2 (see: :doc:`/advanced_topics/jinja2`) by Mikalai Radchuk. Unicode page slugs