A founder reflects on what makes Django so valuable for Buttondown after eight years of use. Key highlights include Django's middleware abstraction for request/response hooks, a custom base model providing UUID keys, change tracking, soft-delete, and provenance tracking with minimal migration overhead, an actions pattern keeping model classes lean, strict function-based views for maintainability, and pytest-based testing without Factory Boy. The post also covers deliberate omissions: signals are avoided internally, class-based views are banned for consistency, Django apps are mostly skipped due to migration complexity, and Django forms are unused in favor of a Vue SPA hydrated via json_script tags. The overall thesis is that Django's best quality is becoming invisible — it structures the codebase without imposing itself.

8m read timeFrom buttondown.com
Post cover image
Table of contents
1. Middlewares2. Models (and light inheritance)3. Actions4. Views5. TestingThe things we leave outWhy did I use Django in the first place?
391 Impressions