Skip to content

Instantly share code, notes, and snippets.

@RobinL
Last active August 29, 2015 14:03
Show Gist options
  • Save RobinL/ef80ed8b316ac4f23b48 to your computer and use it in GitHub Desktop.
Save RobinL/ef80ed8b316ac4f23b48 to your computer and use it in GitHub Desktop.
Simple flask
from flask import Flask
app = Flask(__name__)
from myapp import myapp as myapp_blueprint
app.register_blueprint(myapp_blueprint)
if __name__ == '__main__':
app.run(debug=True)
from flask import Blueprint
myapp = Blueprint('myapp', __name__)
from . import views
from flask import Blueprint
myapp = Blueprint('myapp', __name__)
@myapp.route('/')
def index():
return "Hello world"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment