From 8b169d338e1ea6d07bc3cd0c9ff0b0ae91c56708 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Wed, 16 Jul 2008 22:12:03 +0000 Subject: Doc tweaks. --- repoze/bfg/push.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'repoze/bfg/push.py') diff --git a/repoze/bfg/push.py b/repoze/bfg/push.py index 205c7f26e..49b9cda27 100644 --- a/repoze/bfg/push.py +++ b/repoze/bfg/push.py @@ -2,13 +2,19 @@ import os.path from repoze.bfg.template import render_template class pushpage(object): - """ Decorator for functions which return template namespaces. + """ Decorator for functions which return ZPT template namespaces. - E.g.: + E.g.:: @pushpage('www/my_template.pt') def my_view(context, request): return {'a': 1, 'b': ()} + + Equates to:: + + def my_view(context, request): + return render_template('www/my_template.pt', a=1, b=()) + """ def __init__(self, template): self.template = template -- cgit v1.2.3