Skip to main content

An extension to Flask for easy Genshi templating.

Project description

Flask-Genshi is an extension to Flask that allows you to easily use Genshi for templating. Easily switch between HTML5 and XHTML and have the mimetype set automatically for you.

from flask import Flask
from flaskext.genshi import Genshi, render_response

app = Flask(__name__)
genshi = Genshi(app)

@app.route('/')
def index():
    title = 'Genshi + Flask, a match made in heaven!'
    return render_response('index.html', dict(title=title))

You can install the development version from GitHub with easy_install Flask-Genshi==dev but you probably want the latest stable release:

sudo easy_install Flask-Genshi

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Flask-Genshi-0.5.tar.gz (65.7 kB view details)

Uploaded Source

File details

Details for the file Flask-Genshi-0.5.tar.gz.

File metadata

  • Download URL: Flask-Genshi-0.5.tar.gz
  • Upload date:
  • Size: 65.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for Flask-Genshi-0.5.tar.gz
Algorithm Hash digest
SHA256 0b34553974d6f6a250f28b6f2e952eb58fdad7f1f97b70fa9d0f87564263cda1
MD5 25a5a951e29f83e3d2bc0adbe3d5ecc6
BLAKE2b-256 54577489e44f9b7eb98024210a47c445bcc9a30ad756c69edac513fc3becde9e

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page