File and folder routes for Django views

Hey Djangonauts :wave:

I’ve been thinking about exploring file-based routing for Django views as an alternative to having code for a feature split across forms.py, views.py, urls,py, and template.html. The idea is that all view, form, and template code for a given feature can live together, and the urlpattern can be inferred from the folder structure (a la Next.js and similar frameworks).

Here’s my first stab at this concept, would love to learn what others think and if this idea has any traction: jerivas/django-file-router: File and folder routes for Django views (github.com)

1 Like