Login

Snippets by MattP

Snippet List

Template {% macro %} support, with context rendering

Reuse blocks of template code and content as macros. This is a small extension of https://gist.github.com/skyl/1715202 (which was based on http://djangosnippets.org/snippets/363/) to support rendering macro output into context variables. See comments for details.

  • template
  • tag
  • macro
Read More

MattP has posted 1 snippet.