make:controller Videos#

This page collects the controller-first workflow. It covers simple controller creation, RESTful scaffolding, controller-driven model generation, and the structure choices that come up when the workflow gets more complex.

Use these cards to move through the controller-first path and keep your watched progress saved locally in the browser.

flask make:controller#

Intro To Flask Make Controller Unwatched

When it makes sense to start from controller behavior and how make:controller helps scaffold the layer that coordinates routes, templates, and models.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

The Basics of make:controller#

Create a simple controller Unwatched

How to start with the controller layer directly when the behavior feels clearer than the page or model structure at the beginning.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Add RESTful actions with --crud Unwatched

How the controller generator expands into a full RESTful action set so you can scaffold behavior in one pass instead of method by method.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Why --crud Feels Like A Big Deal Unwatched

Why the --crud flag is such a useful jump in scaffolding power when you want the full RESTful controller, route, and template shape at once.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Controllers and Models with make:controller#

Add a model with --model or -m Unwatched

The difference between the explicit long flag and the shorthand model-generation path so the command does exactly what you intend.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Name the Model Directly Unwatched

How --model lets you choose the exact model name instead of asking Flask-Commands to infer one from the controller name.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Generate the Model Name Unwatched

How -m asks Flask-Commands to generate a model name from the controller name and when that shorthand is clear enough to use.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Why Both Options Matter Unwatched

Why explicit model naming and generated model naming both matter once controller names start carrying namespaces, multi-word models, or relationships.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Generating a RESTful Controller with a Model Unwatched

Watch --crud and -m work together to create a RESTful controller, routes, templates, and a registered model from one controller-first command.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

The Naming Problem Unwatched

The three naming stories Flask-Commands has to separate: one multi-word data structure, a namespace, and a nested resource relationship.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Single Data Structures that are Multiple Words Unwatched

How to keep names like ShoppingList together as one model-backed resource instead of accidentally turning the words into nested structure.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

When to Namespace Unwatched

When a leading name segment is better understood as an organizing namespace rather than a model or parent resource.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Multi-Word Namespaces Unwatched

How multi-word namespaces map to route packages, endpoint names, and URLs while staying separate from the model name itself.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Public Pages and Private Tools Unwatched

How namespaces can separate public resource pages from private tool surfaces that manage the same underlying model.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Naming Nested Controllers by Relationship Unwatched

How nested controller names describe parent-child relationships and how that relationship appears in generated routes and folders.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Go nested with make:controller --crud Unwatched

How the controller-first workflow behaves when the resource is nested and how that changes the generated routes, files, and prompts.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Flat vs Nested with make:controller#

Flat or Nest with the ``-m`` Option Unwatched

What the structure choice means inside the controller-first workflow so you can pick the layout that matches your app instead of accepting a default blindly.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Choose Flat for One Multi-Word Model Unwatched

How --flat keeps a multi-word controller resource together as one model-backed structure when the words describe a single thing.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Build Nested Resources One Level at a Time (make:controller) Unwatched

Why building nested controller resources from the top down keeps generated parents, children, routes, and prompts easier to reason about.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.

Combine Namespaces with Nested Model Generation Unwatched

How controller namespaces and nested model generation can work together when part of the name organizes the app and part describes data relationships.

This video slot is planned for the series. Once a YouTube video is linked, it will expand and play directly on this page.