https://htmx.org - server interactions in HTML
https://alpinejs.dev - small front end tweaks in your HTML
https://tailwindcss.com - styling in your HTML
This is pretty a simple stack that keeps everything in one file (for something I am calling Locality of Behavior[1]) and all of them are dependency free.
full disclosure: I am the author of htmx
Do you have a starter template with all of these hooked together? Or an example repo?
Not to be "that" guy but what you're describing is a .vue file. And with a Vue single file component you have 1 dependency: Vue. With HAT you have 3. Or am I missing something?
If I see this:
<button hx-get="/clicked">Click Me</button>
My immediate question is
* What actually executes when I click the button?
* How can I debug the code that sends the GET request?
* How can I customize the GET request and add stuff like custom headers?
In the jQuery example all of that is obvious on first glance.
I feel like complexity can't be destroyed, only moved around.
There is an hx-headers attribute to modify headers, or you can plug into the events system if need be.
htmx is extending HTML as a hypermedia and, therefore, is a very different model than most javascript-based apps today.
I am not sure if complexity can be destroyed (I'd need to have a solid definition of complexity to discuss that) but it can certainly be managed in different ways, some of which are more effective than others for certain problems. We don't do web programming in assembly for a reason.
Browser differences are mostly disappearing, they have gained some very good APIs are CSS has gained significant layout capabilities with grids and flex. So the need for libraries like jQuery for dealing with DOM differences is disappearing. New standard libraries like Intl and now Temporal make libraries like Moment obsolete.
The web is also gaining a component model with Web Components that will help you get some level of sanity when building some mildly complex reusable stuff. This is probably very good for content heavy sites, which make the majority of the web.
The other part of the web is applications running on top of the Web platform. Those still heavily benefit from frameworks. Having some amount of sanity when managing state is very much welcome. And functional programming models have proven that a declarative way of approaching UIs is much better than dealing with browser APIs imperatively.
So for some years frameworks will still be useful for certain use cases. For the others, we should be embracing Web technologies. Maybe with some light libraries like Stencil and Catalyst.
I genuinely tried React and had to ditch it. Way too much drama just to manage state. It is clearly for building components, not applications.
I don't think comparing the two is relevant. Angular gets in your way if you are just building components but it unleashes a deluge of productivity instantly if you need to build an application--especially for a team.
I almost like ngrx because it reduces boilerplate, but I don't understand why their createAction helper doesn't follow Flux Standard Action; I can't be convinced this isn't a design flaw