>Why should only <a> and <form> be able to make HTTP requests?
>Why should only click & submit events trigger them?
>Why should only GET & POST methods be available?
>Why should you only be able to replace the entire screen?
>By removing these arbitrary constraints, htmx completes HTML as a hypertext"
I guess people do all of these things with javascript anyways but it gave me a "get off my lawn" reaction when I read these bullets.
I'm itching to compare notes.
There's a lot to say about it, but the essential idea is that if you let the server control the state of the application via hypermedia requests/responses, you eliminate a lot of the complexity that is associated with client-side web apps.
Yes, I get that duplicating state on the client and the server is a headache. But are people really doing that? You're just moving the state toward the client and keeping the backend much more thin. Are we going to ignore the past twenty or so years of CPU improvements? I'm not saying just yolo it and do loads of pointless expensive work on the client but 5G and modern phones should have some place in this calculus.
Not saying you have to prefer it, but some of the htmx articles imply there is a difference.
Look at your average JS frontend and you'll find stuff way worse than the things you're complaining about wrt htmx. Live and let live, as they say.
To clarify, if you just use a bit of react that would work well with HTMX. But how many sites use a bit of react without a larger framework wrapped around it?
https://www.reddit.com/r/htmx/comments/160uuzd/whats_the_dif...
So here's a response from the "get off my lawn" crowd.
It's about hypertext. It's always been about hypertext. HTTP is literally "Hypertext Transfer Protocol". The term Hypertext was coined in 1963.
Without Hypertext, Javascript is nothing.
Also, on another note I think HTMX has successfully positioned itself as a meme, for better or worse. I have tried using it on a few side projects and I do like the simplicity of it, but is there a goal of it being credible software, or just something the creators are having fun with?
these are not mutually exclusive outcomes.
He has a great book explaining the philosophy behind the project: https://hypermedia.systems
Seeing "web boomers" having fun and doing their own thing and "young and serious" frontend dev professionals with a career to have acting like the typical know-it-all curmudgeon just warms my heart.
But beware of the deep layers of nerd humour.
https://htmx.org/examples/sortable/ https://htmx.org/examples/modal-bootstrap/
Neither worked for me in Chrome or Safari
I've never used HTMX, but it looks interesting.
I just love the spirit of webrings!
When I think back to early days of the web, I recall the joy and excitement of discovering websites from parts of the world I'd never been and likely never will!
The web doesn't need to be social media network scale. It can be about slow personal discovery.
Sites used to be built for expression and utility, not SEO and the glorification of Likes.
SEO and Google ruined blogging. Facebook ruined social media.
The people need to take the web back! :-)
It replaced a small volume of VueJS code that I wrote to facilitate a few XHR interactions. Pagination and filtering and search-as-you-type interactions are all so much more pleasant now. Logic is de-duplicated, since it can all live on the server.
I'm a fan.