pyramid-breve 0.6.2

Breve template engine renderer add-on for Pyramid
pyramid-breve is an extension for the pyramid framework that allowes users to use the Breve templates as view renderers.

Usage

Call config.include('pyramid_breve') in your WSGI applicatication factory function as following:

def main(global_config, **settings):
 """ This is just an example of how to register renderer for Breve templates.
 """
 config = Configurator(settings=settings)

 config.include('pyramid_breve')

 config.add_static_view('static', 'static', cache_max_age=3600)
 config.scan()

 return config.make_wsgi_app()


Another way is to add it to pyramid.includes in your INI-file:

[app:main]
use = egg:hello_world

pyramid.includes =
 pyramid_breve


Please note that unlike breve.Template which searches for template files under root pyramid_breve renderer uses assets to locate and load templates.

@view_config(route_name='home', renderer='templates/index.b')
def hove_vew(request):
 return {}


@view_config(route_name='login', renderer='my.lovely.package:templates/login.b')
def login_view(request):
 return {}

last updated on:
September 21st, 2012, 0:34 GMT
price:
FREE!
homepage:
github.com
license type:
MIT/X Consortium License 
developed by:
Alexander Kulakov
category:
ROOT \ Internet \ HTTP (WWW)
pyramid-breve
Download Button

In a hurry? Add it to your Download Basket!

user rating

UNRATED
0.0/5
 

0/5

Rate it!

Add your review!

SUBMIT