1. Introduction
Flask was born in 2010 and is a lightweight Web application framework written in Python.
Flask depends on two libraries.
- Jinja2, a template engine similar to mako
- Werkzeug, a Python library that follows the WSGI protocol and implements much of what sits underneath a Web framework, such as the request and response objects.
2. Comparison of Web Frameworks
Features of Flask, Tornado, and Django:
- Flask: lightweight, concise, customizable
- Tornado: asynchronous mechanism
- Django: large and all-inclusive
3. Flask Use Cases
Who uses Flask:
- Guokr
- A large number of personal blogs
- http://flask.pocoo.org/community/poweredby/
It suits small systems; developing a complex system requires the ability to do customized development and to fill in the gaps yourself.
4. Coding Conventions
Projects developed by the Pocoo team
- Flask
- Jinja2
- Pygments
- Sphinx
- Werkzeug
They follow the same set of conventions, which are based on PEP8 with slight differences and a certain amount of extension.
5. Learning Resources
Flask Web Development: Developing Web Applications with Python is not only suitable for beginner Web developers to study and read, but also an excellent reference book for learning advanced Web development techniques.
Mastering Flask starts from a simple Flask application and, by solving a number of practical problems, discusses a series of advanced topics.
jinkan.org Chinese Flask documentation
Flask official English documentation
