mirror of
https://github.com/pallets-eco/flask-debugtoolbar.git
synced 2026-01-05 13:09:45 -06:00
Add setup.py script and an example app
This commit is contained in:
17
example/example.py
Normal file
17
example/example.py
Normal file
@@ -0,0 +1,17 @@
|
||||
from flask import Flask, render_template
|
||||
from flaskext.script import Manager
|
||||
from flaskext.debugtoolbar import DebugToolbarExtension
|
||||
|
||||
app = Flask(__name__)
|
||||
toolbar = DebugToolbarExtension(app)
|
||||
|
||||
@app.route('/')
|
||||
def index():
|
||||
app.logger.info("Hello there")
|
||||
|
||||
return render_template('index.html')
|
||||
|
||||
if __name__ == "__main__":
|
||||
manager = Manager(app)
|
||||
manager.run()
|
||||
|
||||
Reference in New Issue
Block a user