1 Star 0 Fork 0

stoneqp/flask-debugtoolbar

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
README.rst 1.09 KB
一键复制 编辑 原始数据 按行查看 历史
Jeff Widman 提交于 2020-03-09 09:45 . Update README.rst

Flask Debug-toolbar

This is a port of the excellent django-debug-toolbar for Flask applications.

https://travis-ci.org/flask-debugtoolbar/flask-debugtoolbar.png?branch=master

Installation

Installing is simple with pip:

$ pip install flask-debugtoolbar

Usage

Setting up the debug toolbar is simple:

from flask import Flask
from flask_debugtoolbar import DebugToolbarExtension

app = Flask(__name__)

# the toolbar is only enabled in debug mode:
app.debug = True

# set a 'SECRET_KEY' to enable the Flask session cookies
app.config['SECRET_KEY'] = '<replace with a secret key>'

toolbar = DebugToolbarExtension(app)

The toolbar will automatically be injected into Jinja templates when debug mode is on. In production, setting app.debug = False will disable the toolbar.

See the documentation for more information.

马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/stoneqp/flask-debugtoolbar.git
git@gitee.com:stoneqp/flask-debugtoolbar.git
stoneqp
flask-debugtoolbar
flask-debugtoolbar
master

搜索帮助

23e8dbc6 1850385 7e0993f3 1850385