@@ -219,18 +219,19 @@ Each page is also put together as Django renders it, and read once more (#273):
219219templates it extends, each block taking the definition of the most derived one and `{{
220220block.super }}` the next one up, and each template it includes in place. What a child's
221221block prints inside its parent's ` <script> ` , or what an include puts inside an
222- attribute, is read where it lands. ` {{ block.super }} ` is put in place only bare:
223- through a filter or a tag, Django still prints the parent's markup, marked safe, and the
224- template is not established. A name several files have, which Django resolves through
225- loaders the analyzer does not read, counts as each of them: a page extending it must
226- escape with each file, except those already in its chain, which Django leaves out, so
227- that a template extending its own name extends another file of it; an include of it is
228- accepted only in HTML data, never inside an attribute, a tag, a ` <script> ` or ` <style> `
229- block or a comment, and only when each file ends in HTML data, nothing of it left open.
230- A template including itself is read the same way. A page beyond 8 MiB once put together,
231- or a template with more than 64 pages, or 16 MiB in all, through the files the templates
232- it extends may be, is not established, and is listed among the templates the analyzer
233- could not read.
222+ attribute, is read where it lands. ` {{ block.super }} ` is put in place only bare: the
223+ variable ` block ` named anywhere else, through a filter, a tag or an alias (`{% with
224+ parent=block %}{{ parent.super }}`), may still print the parent's markup, marked safe,
225+ and the template is not established. A name several files have, which Django resolves
226+ through loaders the analyzer does not read, counts as each of them: a page extending it
227+ must escape with each file, except those already in its chain, which Django leaves out,
228+ so that a template extending its own name extends another file of it; an include of it
229+ is accepted only in HTML data, never inside an attribute, a tag, a ` <script> ` or
230+ ` <style> ` block or a comment, and only when each file ends in HTML data, nothing of it
231+ left open. A template including itself is read the same way. A page beyond 8 MiB once
232+ put together, or a template with more than 64 pages, or 16 MiB in all, through the files
233+ the templates it extends may be, is not established, and is listed among the templates
234+ the analyzer could not read.
234235
235236The analyzer never assumes escaping where it cannot read the template. That covers a
236237template file it cannot read, a template named by an expression, a template found
0 commit comments