Problem/Motivation
Two of the request headers used by HTMX use the HTML id property. Since these can be dynamic in Drupal, a data-drupal-selector is provided by core.
Proposed resolution
Add to `htmxDrupalPageState()`
// Swap in drupal data selectors as #id values are altered to be unique.
configRequestEvent.detail.headers['HX-Target'] = configRequestEvent.detail.target.dataset.drupalSelector;
configRequestEvent.detail.headers['HX-Trigger'] = configRequestEvent.detail.elt.dataset.drupalSelector;
Issue fork htmx-3488016
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #4
fathershawnComment #5
fathershawn