3 ms·
I am trying to articulate a design principle to overcome the resistance to "putting X into the HTML" called "Locality of Behavior" (LoB): https://htmx.org/essa
by recursivedoubts 5y ago
I am trying to articulate a design principle to overcome the resistance to "putting X into the HTML" called "Locality of Behavior" (LoB):
https://htmx.org/essays/locality-of-behaviour/ https://htmx.org/essays/locality-of-behaviour/
This terminology can be used in design discussions to respond to criticisms of the "into the HTML" approach and, in particular the well know "Separation of Concerns" (SoC) design principle.
- leephillips 5y agoI like this, and htmx very much. The only problem I see (and this is minor, and not a criticism at all) is that online HTML validators complain about the hx- attributes. Same issue with Alpine. So when I use these I can no longer brag that my site has zero validation errors. I know that these errors are of no consequence and don’t interfere with the browser parsing the HTML, but still.
- recursivedoubts 5y agoYou can use a data- prefix with all hx- attributes if you'd like, which should allow it to validate.
- leephillips 5y agoThanks for that idea!