summaryrefslogtreecommitdiffstatshomepage
path: root/dist/htmx.amd.js
diff options
context:
space:
mode:
Diffstat (limited to 'dist/htmx.amd.js')
-rw-r--r--dist/htmx.amd.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/dist/htmx.amd.js b/dist/htmx.amd.js
index 472ece49..6e506f4a 100644
--- a/dist/htmx.amd.js
+++ b/dist/htmx.amd.js
@@ -290,7 +290,7 @@ var htmx = (function() {
location,
/** @type {typeof internalEval} */
_: null,
- version: '2.0.5'
+ version: '2.0.6'
}
// Tsc madness part 2
htmx.onLoad = onLoadHelper
@@ -2436,7 +2436,9 @@ var htmx = (function() {
if (elt.form && elt.type === 'submit') {
return true
}
- if (elt instanceof HTMLAnchorElement && elt.href &&
+ elt = elt.closest('a')
+ // @ts-ignore check for a link wrapping the event elt or if elt is a link. elt will be link so href check is fine
+ if (elt && elt.href &&
(elt.getAttribute('href') === '#' || elt.getAttribute('href').indexOf('#') !== 0)) {
return true
}