Skip to main content

Template support for flask application

Project description

Template support for flask application

Quickstart

Install flask_template_support using pip:

$ pip install Flask-TemplateSupport

Example usage

from flask import render_template
from flask_template_support import TemplateSupport


def test_sum(a, b):
    return a + b


def test_sub(a, b):
    return a - b


app = Flask(__name__)
ts = TemplateSupport()

ts.init_app(app, functs=(
        (test_sum, 'sum'),
        (test_sub, 'sub'),
    ))

Run test.py in example folder and go to http://127.0.0.1:5000/ to see if it works

License MIT

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-TemplateSupport-1.0.1.tar.gz (3.2 kB view details)

Uploaded Source

File details

Details for the file Flask-TemplateSupport-1.0.1.tar.gz.

File metadata

  • Download URL: Flask-TemplateSupport-1.0.1.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.3

File hashes

Hashes for Flask-TemplateSupport-1.0.1.tar.gz
Algorithm Hash digest
SHA256 74c932a0d78e83b73bd905f1edfc19bc69862e4cd56e984d85543f7f1e059f27
MD5 a5997328b1946b40ed82841084983874
BLAKE2b-256 74764b8a3688229dbad4b6c754b81dc782cb45f1f70db3a107cc94925ac0ff66

See more details on using hashes here.

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