Common Django Project structures - Part 3

The final project layout I will explain for now, is one that is for the simplest of projects. One where building a single Django app is too much boilerplate. This concept is nothing new as Will Vincent & Paolo Melchiorre have shown most recently with μDjango.

This example does not take it to their extreme, but it's usage is more for very simple prototypes or demos. To get started simply add the files typically found in a Django app (eg models, views, migrations etc) directly into your project folder next to your settings file. This directory structure shows what I mean:

├── db.sqlite3
├── manage.py
└── project
    ├── __init__.py
    ├── asgi.py
    ├── models.py
    ├── settings.py
    ├── urls.py
    ├── views.py
    └── wsgi.py

Then simply add the project directory name to INSTALLED_APPS:

INSTALLED_APPS = [
  ...
  "project"
]

and voila you have a working Django project with all the features you need.

Have I missed an obvious project layout? Let me know in the comments on socials or drop me an email!