From: David Lord Date: Wed, 18 Dec 2024 17:36:11 +0000 (-0800) Subject: clarify block outer scope docs X-Git-Tag: 3.1.5~25^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F2060%2Fhead;p=thirdparty%2Fjinja.git clarify block outer scope docs --- diff --git a/docs/templates.rst b/docs/templates.rst index 0eab8e66..d5f2719e 100644 --- a/docs/templates.rst +++ b/docs/templates.rst @@ -528,8 +528,8 @@ However, the name after the `endblock` word must match the block name. Block Nesting and Scope ~~~~~~~~~~~~~~~~~~~~~~~ -Blocks can be nested for more complex layouts. However, by default blocks -may not access variables from outer scopes:: +Blocks can be nested for more complex layouts. By default, a block may not +access variables from outside the block (outer scopes):: {% for item in seq %}
  • {% block loop_item %}{{ item }}{% endblock %}