Live data from Hacker News

Django: what’s new in 6.0

adamj.eu

51–60 of 127 posts

Re: Django: what’s new in 6.0

#51

Earlier quoted context omitted.

There've been a variety of open source attempts at this idea. Is this official one now the best to use, or are the others still compelling?

https://django-cotton.com/ is component-based. I used it a bit, it's nice if you're used to the ways of front-end frameworks, I guess.

https://github.com/django-components/django-components also looked interesting

Re: Django: what’s new in 6.0

#52

Earlier quoted context omitted.

https://django-cotton.com/ is component-based. I used it a bit, it's nice if you're used to the ways of front-end frameworks, I guess.

https://github.com/django-components/django-components also looked interesting

While using Cotton my thoughts were "ok, it's kinda cool... but do I really need it ? No. Is it worth the extra dependency ? No."

There is something very appeasing in just pulling Django and have all the basics covered. It's nice to have options when needed though.

Re: Django: what’s new in 6.0

#53
Template Partials and HTMX seems like the Django equivalent of View Components and Stimulus for Rails, which is nice.

Also, good to see first class support for Tasks, among a lot of other niceties!

Re: Django: what’s new in 6.0

#54

Template partials look good, which is one of the key reasons frameworks like React are as good and popular as they are, because you can reuse small segments of code.

Key benefit for reusability and composability in React is IMHO that they don't use templates at all, but everything is a function.

Exactly. There are a few libraries to achieve a similar thing in Python:

* https://htpy.dev/

* https://pypi.org/project/fast_html/

* https://fastht.ml/ (different to above, I think)

* https://github.com/volfpeter/fasthx

Probably others. I strongly prefer this to templating, but I find it makes dyed in the wool Django people squirm.

Re: Django: what’s new in 6.0

#55

Template Partials and HTMX seems like the Django equivalent of View Components and Stimulus for Rails, which is nice. Also, good to see first class support for Tasks, among a lot of other niceties!

If I understood correctly, to use Tasks in production right now you need to use this as well:

https://github.com/RealOrangeOne/django-tasks

Is that correct?

Re: Django: what’s new in 6.0

#56
post #42

Template partials look good, which is one of the key reasons frameworks like React are as good and popular as they are, because you can reuse small segments of code.

Amazing that Django didn't have this until 2025

Wouldn’t Jinja2 macros count?

Re: Django: what’s new in 6.0

#57

Earlier quoted context omitted.

Why is celery awful?

> The Many Problems with Celery: — https://steve.dignam.xyz/2023/05/20/many-problems-with-celer... > The problems with (Python’s) Celery: — https://docs.hatchet.run/blog/problems-with-celery > Dramatiq motivation: — https://dramatiq.io/motivation.html Here are some alternatives: Dramatiq: https://github.com/Bogdanp/dramatiq RQ: https://github.com/rq/rq Huey: https://github.com/coleifer/huey Hatchet: https://github.co…

django-q2: https://github.com/django-q2/django-q2

Re: Django: what’s new in 6.0

#59
I love how Django just keeps slowly improving at every release. 6.0 is especially cool, including lots of really useful new features. Who said dependable tech was dull - this is the way is should be done. Well done all who contribute.

Re: Django: what’s new in 6.0

#60
post #58

Given that Python tends to produce fewer hallucinations when generated by LLMs I wonder if former Django developers using AI tools are secretly having a blast right now.

I think another ace up Django's sleeve is that it has had a remarkable stable API for a long time with very few breaking changes, so almost all blogposts about Django that the LLM has gobbled up will still be mostly correct whether they are a year or a decade old.

I get remarkably good and correct LLM output for Django projects compared to what I get in project with more fast moving and frequently API breaking frameworks.

Post reply on HN