This is the 26th day of my participation in Gwen Challenge


Introduction of Flask

Flask is a Python implemented Web development microframework. Flask has been designed as an extensible framework since the beginning of development.

Flask has two main dependencies: routing, debugging, and the Web Server Gateway Interface (WSGI)

The WSGI toolkit uses Werkzeug (routing module) and the template engine uses Jinja2.



It can be said that the core of the Flask framework is Werkzeug and Jinja2.

The most famous Python framework is Django, along with Flask, Tornado and others. Flask is not the best known framework, but Flask is one of the most flexible frameworks, which is why Flask is so popular with developers.


Contrast Django with Flask

Django is versatile, providing a one-stop solution that integrates MVT (Model-View-Template) and ORM, as well as back-end administration. Become a perfectionist in Web development. But the disadvantage is also obvious, it is too heavy. It’s like a house that has been renovated, and it provides what you need, and you can just use it. Most decisions have already been made for you, making it difficult (and sometimes impossible) to use alternatives.


Flask is a lightweight Web framework compared to Django. Just like the blank room, how to decorate by their own design. Flask is lightweight, compact, and scalable by customizing third-party extensions for specific functions.


Flask common extension

Flask itself is a kernel that uses extensions to implement advanced functions such as ORM operation databases and login permission authentication.

Developers can pick and choose which extensions fit the needs of the project. Here are a few of Flask’s commonly used extensions.

  • Flask-SQLalchemy: Operation database;
  • Flask-migrate: Manage the migration database;
  • Flask-Mail: mail;
  • Flask-WTF: form validation;
  • Flask-script: Insert script;
  • Flask-Login: Indicates the authentication user status.
  • Flask-RESTful: tools for developing REST apis;
  • Flask-Bootstrap: Integrated front-end Twitter Bootstrap framework;


Flask Learning website

  • Flask http://docs.jinkan.org/docs/flask/ Chinese documents
  • https://flask.palletsprojects.com Flask English document


The public,

Create a new folder X

Nature took tens of billions of years to create our real world, while programmers took hundreds of years to create a completely different virtual world. We knock out brick by brick with a keyboard and build everything with our brains. People see 1000 as authority. We defend 1024. We are not keyboard warriors, we are just extraordinary builders of ordinary world.