Hacker News new | ask | show | jobs
by sesm 1041 days ago
What are technical differences between HTMX and early versions of Angular 1? It has the same idea of sprinkling some attributes over HTML to make it dynamic for easy cases. There were many frameworks that started like this (Angular 1, Vue, etc), and after getting some traction they grew into full-blown SPA frameworks, because there is a real need for more difficult cases.

If I had to pick an “Angular-1-like” framework, I would pick the one that clearly documents it’s boundaries and provides a clear way to use a mature SPA framework when there is a need to cross those boundaries. If anyone is aware of such framework, please share.

1 comments

htmx uses hypermedia, rather than client-side managed state

as much as possible, htmx tries to take HTML to its logical conclusion (from my perspective) as a hypermedia, rather than imposing other ideas on top of it

You keep using the term hypermedia and I'm not certain what is meant by that term (I was thinking it referred to linked media). Hyper means over, right? So is hypermedia more about the environment media is in than it is about links?
yes, I prefer the term hypermedia over hypertext because it stresses the systemic nature of a hypermedia system: a hypermedia (e.g. HTML, a hypertext), a hypermedia client (e.g. a web browser), a hypermedia protocol (e.g. HTTP) and hypermedia servers.

we have written a book on the topic here:

https://hypermedia.systems/

you can read chapters 1 & 2 for an overview of what hypermedia is at a systems level:

https://hypermedia.systems/hypermedia-reintroduction/

https://hypermedia.systems/hypermedia-components/

As far as what the term _hypermedia_ means: it is a media, such as a text, that includes within it _hypermedia controls_. Those hypermedia controls allow non-linear branching and interactions with the media, hence the term _hyper_, that is, above, "normal" media, which is consumed passively.

The hypermedia controls we are all most familiar with are anchors/links & and form tags. htmx attempts to generalize the concept of a hypermedia control.

The book goes into gory detail if you are interested in further exploring the idea.

I think he meant just hypertext
Does this ideology lead to significant technical differences from early versions of Angular 1 and early versions of Vue?
Ok, I see, the idea is to render parts of the page on server and swap those parts on the client with things like: https://htmx.org/attributes/hx-swap/

So it's not really an "Angular-1-like", but more like Vaadin in JS.