First time here? Check out the FAQ!
0

macro hides all other variables?

does macro hide all other variables passed from views?

pcompassion's avatar
21
pcompassion
asked 2013-08-01 06:39:17 -0600
edit flag offensive 0 remove flag close merge delete

Comments

add a comment see more comments

1 Answer

0

Yes, Jinja2 macros have only access to variables passed explicitly, or via other special channels that Jinja2 templating uses.

This may be circumvented by creating custom template filter functions as inside functions it is possible to do more.

Evgeny's avatar
13.2k
Evgeny
answered 2013-08-01 16:52:04 -0600
edit flag offensive 0 remove flag delete link

Comments

add a comment see more comments