Building Maintainable CRUD in Django
summary
Claims a small set of rules for maintainable CRUD and demonstrates them by built the app three ways — function based views, Django generic class based views, and the Neapolitan library approach; uses a sample library app and points out a legacy project with dozens of models and duplicated templates; shows that Neapolitan centralizes behavior in a 513-line CRUD view that makes overrides local and testable; advises creating an app-specific generic CRUD layer, using mixins for nav and permissions, and placing transaction boundaries on the overridden methods.
AI-written summary · about
chapters (14)
- 0:00Introduction to maintainable CRUD
- 4:21Problems with generic views
- 9:00Function-based vs class-based views
- 11:35Rules for maintainable CRUD
- 16:43Introducing Neapolitan
- 21:04When to use Neapolitan
- 24:39Anchor CRUD layer in intentions
- 26:05Q&A: Choosing the right approach
- 27:48Q&A: Mixins and complexity
- 28:53Q&A: Locality of behavior in mixins
- 29:58Q&A: Atomic transactions
- 31:31Q&A: What is Neapolitan?
- 32:35Q&A: Breaking changes in base classes
- 34:01Closing remarks
