HTMX should have a way to have JS modify the response before it is inserted/handled.
<div hx-preinsert="myfunc">Old Content</div>
<script> function myfunc(callingElement, serverResponse){
return modified-Server-Response
}
IMO, aside from the fact that such a feature really is needed, the lack thereof pushes people to Marko, Livewire, etc, simply because they need to do add some tiny detail which is available in the JS. Besides that it makes HTMX look like a toy that values purity (no frontend JS) over practicality.I know there are ways to build a plugin, but do not have the time or headspace to figure it out.