【发布时间】:2011-11-17 15:20:25
【问题描述】:
我特别想使用pystache,但任何其他模板引擎的指南都应该足以设置它。
如果我理解正确,我必须在我的金字塔应用程序的__init__.py 中注册渲染器工厂。
config = Configurator(settings=settings)
config.add_renderer(None, 'pystache_renderer_factory')
现在我需要创建渲染器工厂,不知道怎么做。
虽然我找到了the documentation关于如何添加模板引擎,但我没有设法设置它。
【问题讨论】:
标签: python pyramid template-engine mustache