No project description provided
Project description
Bottle PyPugjs Template
Este es un plugin de bottle para poder usar la libreria de pypugjs en las vistas
Inicio rapido
El plugin de bottle-pypugjs permite usar la tres formas que bottle define para manejar los templates
.. code-block:: python
from bottle import route, install
from bottle.ext.pypugjs import template, view, Plugin
# Usando la funcion template
@route('/index')
def index():
return template('index.pug')
# Usando el decorador view
@route('/index')
@view('index.pug')
def index():
return {}
app.install(Plugin())
# Usando el argumento *template* en la ruta que provee el plugin
@route('/index', template='index.pug')
def index():
return {}
Con estos ejemplos se resume el funcionamiento del plugin.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
bottle-pypugjs-0.1.0.tar.gz
(3.4 kB
view hashes)
Built Distribution
Close
Hashes for bottle_pypugjs-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a1d863a4dea95bb2ea105e88f4631d1207da3e91c183cf5d113c233beeb329e7 |
|
MD5 | 53a60236ea5f0af16a4856336bbdee6f |
|
BLAKE2b-256 | 85e6028ac84ebe6bac487999f2e2302935b35f088d81218daba41ca8d1186e34 |