Include is executed whether or not the condition is true. It is not python code therefore it is executed before the python code is executed. It is not a good idea to put the include in a condition.
On Mar 9, 12:24 pm, m t <monsun...@gmail.com> wrote: > Hi, > > I have such code: > {{if someData:}} > {{include 'additional.html'}} > {{pass}} > > problem is that even when 'someData' is NOT true - file > 'additional.html' is included. > > Is there some trick to select on view level which includes shall be > loaded?