Minimal routing extension for Flask
Project description
Flask-Mux is a lightweight Flask extension that provides a routing system similar to that of Express.js. It basically wraps Flask’s url route registrations API to add more flexibility.
Installing
Install using pip:
$ pip install Flask-Mux
A Simple Example
from flask import Flask
from flask_mux import Mux, Router
app = Flask(__name__)
mux = Mux(app)
def home():
return 'home'
def about():
return 'about'
index_router = Router()
index_router.get('/', home)
index_router.get('/about', about)
mux.use('/', index_router)
User’s Guide
You’ll find the user guide and all documentation here
Links
Documentation: https://emr-flask-mux.readthedocs-hosted.com/en/latest/
PyPI Releases: https://pypi.org/project/Flask-Mux/
Source Code: https://github.com/ElMehdi19/flask-mux/
Issue Tracker: https://github.com/ElMehdi19/flask-mux/issues/
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
Flask-Mux-0.0.2.tar.gz
(6.4 kB
view hashes)
Built Distribution
Close
Hashes for Flask_Mux-0.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4b874b785248476129691006f19e4657f0bf2bf23f6f7a3171c1c1566a21924b |
|
MD5 | 5470e876260d4859615275219730bff6 |
|
BLAKE2b-256 | c04a2d7c7c84f4df9b6428df3b58010399a8a45ff0bc2badebdb4dc7c1d9b522 |