I'm new to MoinMoin and flask. I have a moinmoin site using python macros. For the moment, I just use some basic string format method to return html from my macro. I would like to use the flask templates with the render_template
method. It doesn't work for now, because the context stack seems to be empty. I don't really know what is the good way of making it work. Should i create a context with flask by giving to it the macro object itself or the macro request ?
Asked
Active
Viewed 264 times
1

Viviane
- 137
- 1
- 8
1 Answers
0
When you are using a macro you are most likely using a Jinja2 macro (Python doesn't have macros). In that case you can use the include
or import
directives to load other Jinja templates and render them.

Sean Vieira
- 155,703
- 32
- 311
- 293
-
I was using moinmoin macros, but yes the solution was to render directly the jinja templates and not to use flask. Thank's! – Viviane Mar 06 '13 at 09:23