Flask extensions are modules you import, (usually) initialize, and use to integrate with third-party libraries. They're (also) usually imported from flask.ext.<extension_name>
(which is part of the extension pattern) and should be available in the PyPi repository under the BSD, MIT, or another less restrictive license.
It's good practice for an extension to have two states: uninitialized and initialized. This is good practice because your Flask application may not be available at the time you instantiate your extension. Our example in the previous chapter only initializes Flask-SQLAlchemy after it is imported in the main module. Ok, nice to know but how is the initialization process important?
Well, it's through the initialization that the extension fetches its configuration from the application. For example:
from flask import Flask import logging # set configuration for your Flask application or extensions class Config(object): LOG_LEVEL = logging.WARNING...