Book Image

Mastering Flask [Video]

By : Jack Stouffer, Alexander Putilin
Book Image

Mastering Flask [Video]

By: Jack Stouffer, Alexander Putilin

Overview of this book

Leverage the small but powerfully-formed Flask framework and its extensibility About This Video • Get an in-depth look at the Python web micro-framework • Take advantage of Flask’s extensibility to perform advanced web application development • Develop a real-world application using best practices to reduce its development and maintenance time In Detail Flask is a small and powerful web development framework for Python. It is called a micro-framework as it aims to keep the core simple but extensible. Even though it’s called a micro-framework, it is no way lacking in functionality, and allows you to develop applications very quickly, primarily through the development of a small codebase. This course will take you deep into the world of using Flask and its ecosystem of extensions to create web applications. We’ll walk through creating a simple IMDB clone from scratch. We’ll start by creating the boilerplate code and use Virtualenv to create an isolated development environment. You’ll then learn to work with the database using SQLAlchemy. After that, we’ll display our data to the end user using WTForms. We’ll restructure and modularize our code using Blueprints. Our site will be secured using the extensions Flask-Login and Flask-Principal. After that, we’ll create a RESTful API of our app. We’ll then give admin functionality and extend our app using various flask extensions. We’ll incorporate Celery to make our tasks asynchronous. We’ll walk you through performing unit test of our app, and then test our SQLAlchemy models. We’ll also test the URLs and finally, we’ll test how much of our code isn’t being tested. All these tests will make our app secure. Finally, we’ll deploy our Flask app to various options that are available. This course will give you an in-depth understanding of how to use Flask and its strong extensibility for more complex web applications.
Table of Contents (11 chapters)
Chapter 7
Creating an Admin Interface
Content Locked
Section 2
Interfacing with Models
The only way to create new data in the database currently is to use the shell interface. We need an administrator interface to add data from the Web. - Interface our SQLAlchemy models with Flask Admin - Enable Flask Admin's advanced searching features - Add extra form elements to the edit pages to allow picture uploads