htmx icon indicating copy to clipboard operation
htmx copied to clipboard

Support `5xx` syntax for response-targets

Open spiffytech opened this issue 1 year ago • 6 comments

It appears that Rust's Maud HTML templating tool doesn't support asterisks in HTML attribute names, as used in the response-targets extension.

I wouldn't be surprised if there are other tools that don't support the syntax, given I can't recall seeing it used anywhere else.

I considered asking Maud to add support, but it looks like the asterisks might violate the HTML spec: while HTML built-in attributes seem allowed to use them, data- attributes and attributes on custom elements can't.

Given that, I request that the response-targets extension support an alternate wildcard syntax, hx-target-5xx, that's unambiguously HTML-compliant.

spiffytech avatar Jul 11 '23 19:07 spiffytech