This is surprising because the template language in particular feels so anti-PHP, it’s highly opinionated about not mixing code in with the template. I often wish it supported arbitrary Python.
Yeah, the template language was strongly influenced by NOT wanting to allow arbitrary logic like PHP does. I was already a fan of Smarty - https://www.smarty.net/ - which did a great job of separating out presentation logic in PHP.
I've been using Jinja for my own projects for a few years because I wanted more expressive Python code in my templates! I think we didn't quite get the balance right for that in Django.
I think a great combo would've been Django's features, packaging and most importantly documentation, but with SQLAlchemy and Jinja2 technologies underneath.
The nice thing about Django is that there's nothing stopping you from doing that. You'll have to give up the Django Admin if you use SQLAlchemy for models but you can still do it. I have several projects that use Elasticsearch as a backend and one that's based on JSON documents in Git repositories. You can totally do it!
That would have been hard since both of those projects came out after Django, but just an FYI Jinja2 templates are supported and nothing stops you from using SQLAlchemy. Granted you lose a lot of the tight intergration that makes Django great to use.
Idiorm was started in early 2010 while I was still writing PHP professionally. I’d heard about Django from a talk @simonw gave at the FlashBrighton meet-up group in 2009 and immediately fell in love. Idiorm and Paris, although not direct attempts to duplicate Django’s ORM, came from frustration that such an elegant ORM and query builder didn’t exist in the PHP world.
So in a roundabout way, Laravel’s ORM was absolutely inspired by Django.
As a side note, I’m still doing Django 16 years later and love it more than ever.
Right. I love Python and Django but the "batteries included" claim seems like an anachronism.
Job queues, WebSockets/SSE, setter/modern form rendering, API framework, components, comprehensive CLI, frontend support etc are what the competition have better integrates and/or first party.
It's likely the template-centric architecture with its own template language and the monolithic approach to web development - both Django and traditional PHP frameworks like Laravel share this pattern of tightly coupling views with server-side rendering.