From: Armin Ronacher Date: Sat, 10 Nov 2007 23:11:37 +0000 (+0100) Subject: document single inheritance X-Git-Tag: 2.0rc1~239 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=c5b509f270b556266e53359fa525a304761a9a7b;p=jinja2.git document single inheritance --HG-- branch : trunk --- diff --git a/docs/src/inheritance.txt b/docs/src/inheritance.txt index 0b7941a..d9d0cdc 100644 --- a/docs/src/inheritance.txt +++ b/docs/src/inheritance.txt @@ -9,6 +9,7 @@ elements of your site and defines **blocks** that child templates can override. Sounds complicated but is very basic. It's easiest to understand it by starting with an example. + Base Template ============= @@ -42,6 +43,7 @@ In this example, the ``{% block %}`` tags define four blocks that child template can fill in. All the `block` tag does is to tell the template engine that a child template may override those portions of the template. + Child Template ============== @@ -143,6 +145,12 @@ an syntax error. Here some examples: and defines a new block subtemplates can override. +.. admonition:: Note + + Unlike Python Jinja does not support multiple inheritance. So you can + only have one extends tag with only one constant string argument. + + Super Blocks ============