Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Nothing is stopping one from adding a bit of javascript when needed. Or complimenting with something like alpine or jquery.


This is why I never understood htmx. Vanilla react is pretty easy to get started with, you just create a root component and mount it to a DOM element.

Maybe 10 lines of code.

Then you can go as simple or as complex as you want without having to awkwardly rig it up to another UI system.


Htmx (re)uses html and doesn’t require learning a new paradigm or loading heavyweight libs.


Except it requires learning a bunch of new paradigms including a full on custom DSL, and requires loading a library that is that is at best as heavy as most competition


Not at all, simple things are simple.


Simple things are simple everywhere.

And then suddenly you need to be aware of the quirks: https://htmx.org/quirks/

And then you need your backend to handle all the weird new headers: https://htmx.org/reference/#request_headers

And then you need to learn completely non-HTML things like "attribute inheritance" https://htmx.org/docs/#inheritance

And then you need to learn a whole new DSL https://htmx.org/docs/#trigger-modifiers

HTMX probably has more concepts than react at this point in time.


These examples are trivial and/or rare, especially in comparison to the monstrosity of a SPA framework. I picked up htmx in an hour or two.

I do think it is a bit overengineered however, though there are other implementations of the idea.


> comparison to the monstrosity of a SPA

What you call "monstrosity" is just as trivial and rare.

See how this works?

You claimed that HTMX doesn't require learning new paradigms. When it's actually a new paradigm replete with multiple different requirements, custom DSLs, new behaviors etc.


It uses html’s paradigm, which is a masterstroke. You keep using the term DSL as if it’s appreciably different than “put a string in an attribute.”

Htmx is an order of magnitude easier to get started with for a person who already knows html, ask me how I know.


You don’t have to use an SPA framework. Hopefully you don’t think you need one to use react.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: