💾 Archived View for gemini.ctrl-c.club › ~cst › htmx.gmi captured on 2022-06-03 at 23:38:41. Gemini links have been rewritten to link to archived content
-=-=-=-=-=-=-
Htmx encapsulates js code into HTML attributes. It enhances HTML, the hypermedia itself.
It seems to me like a very elegant solution, and very much inline with the original vision of the hypermedia.
An excerpt from the htmx site:
By removing these arbitrary constraints, htmx completes HTML as a hypertext
htmx examples implemented with flask/python
The examples are an excellent place to start reviewing the technology in more detail.
I'd say that it is an excellent tech to provide more flexible frontend to existing or new server site generated dynamic site.
E.g. if you have e.g. python/flask/jinja app, you could enhance your jinja templates with htmx. Combine that with jinja-partials and you'd have maximum frontend kick, while retaining the full power of your server side processing and templates, etc, etc.
More on htmx as a paradigm - HTML fragments over the wire/HATEOAS
htmx: Writing JavaScript to Avoid Writing JavaScript, by Carson Gross
HTMX + Flask: Modern Python Web Apps, Hold the JavaScript - Michael Kennedy
How Tailwind CSS and HTMX promote locality of behavior
https://edofic.com/posts/2022-01-28-low-js/
https://dev.to/nicholas_moen/what-i-learned-while-using-django-with-htmx-and-alpine-js-24jg