Reputation: 1472
How can I use a jinja2 template with a .html extension in pyramid? For instance, I want the view configuration to look like,
@view_config(context=MyModel, renderer='templates/index.html')
def home_view(request):
...
Is it possible?
Upvotes: 3
Views: 1351
Reputation: 23331
config.add_renderer('.html', 'pyramid_jinja2.renderer_factory')
Upvotes: 17