Loading presentation...
Prezi is an interactive zooming presentation

Present Remotely

Send the link below via email or IM

Copy

Present to your audience

Start remote presentation

  • Invited audience members will follow you as you navigate and present
  • People invited to a presentation do not need a Prezi account
  • This link expires 10 minutes after you close the presentation
  • A maximum of 30 users can follow your presentation
  • Learn more about this feature in our knowledge base article

Do you really want to delete this prezi?

Neither you, nor the coeditors you shared it with will be able to recover it again.

DeleteCancel

Make your likes visible on Facebook?

Connect your Facebook account to Prezi and let your likes appear on your timeline.
You can change this under Settings & Account at any time.

No, thanks

Why Flask is fun!

No description
by

Alan Hamlett

on 5 November 2014

Comments (0)

Please log in to add your comment.

Report abuse

Transcript of Why Flask is fun!

Alan Hamlett
* Founder & CTO, WakaTime (wakatime.com)
* Full stack dev
* @alanhamlett on GitHub & Twitter
Flask is Simple
from datetime import datetime
from flask import Flask, request, jsonify

app = Flask(__name__)

@app.route("/")
def index():
data = {
"current_time": datetime.now().strftime("%I:%M %p %a %b %d %Y"),
"url_args": request.args,
"user_agent": request.headers.get('User-Agent'),
"ip_address": ','.join(request.access_route),
}
return jsonify(data=data)

if __name__ == "__main__":
app.run()
Running Flask
virtualenv venv
source venv/bin/activate
pip install Flask
python hello.py
* Running on http://localhost:5000/
Your Flask Website
Flask Meets Your Needs As You Scale
* BluePrints

* Extensions
What's Flask?
Why Flask is fun!
* helps you build a Python website

* wraps a web server and template engine

* as simple as you want

* as scalable as you want
Flask-Admin ( admin interface )

Flask-Login ( user auth )

Flask-SQLAlchemy ( database ORM )

WTForms & WTForms-JSON ( user-input validation )

Alembic ( database schema migrations, like South )

Flask-SeaSurf ( CSRF protection )

jinja-assets-compressor ( compress static files )

Flask-Mail ( send email easily )

Flask-Script ( command line scripts )
https://gist.github.com/alanhamlett
http://bit.ly/1x5ckio
Find this online at http://bit.ly/1x5ckio
Full transcript