July 2018
Intermediate to advanced
324 pages
8h 14m
English
In any Flask project, we create the Flask application object and refer to the file path with a value to the FLASK_APP argument or environment variable. In our case, we created a modular application that has separate modules defined for specific operations, but now we need to combine all of these modules in one place. We have already seen the blueprint objects and their integration. Here, we will look at the actual process of combining the blueprint and other required extensions.
The following is the code snippet for the Flask application object.
File—app/__init__.py:
from flask import Flaskfrom flask_sqlalchemy import SQLAlchemyfrom flask_login import LoginManagerfrom flask_migrate import Migratefrom flask_wtf.csrf import CSRFProtect ...
Read now
Unlock full access