summaryrefslogtreecommitdiffstatshomepage
path: root/src/ext/path-deps.js
diff options
context:
space:
mode:
authorcarson <carson@leaddyno.com>2021-11-12 15:37:29 -0700
committercarson <carson@leaddyno.com>2021-11-12 15:37:29 -0700
commit2944bf372c1292199c9ba81c6038bd8aec21efd0 (patch)
tree030737545705d91915f34d054e4a4f8a8209a509 /src/ext/path-deps.js
parent8f159657973e34a8fc854f76246de58f217153e3 (diff)
downloadhtmx-2944bf372c1292199c9ba81c6038bd8aec21efd0.tar.gz
htmx-2944bf372c1292199c9ba81c6038bd8aec21efd0.zip
search for extensions in new content
fixes https://github.com/bigskysoftware/htmx/issues/281
Diffstat (limited to 'src/ext/path-deps.js')
-rw-r--r--src/ext/path-deps.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/ext/path-deps.js b/src/ext/path-deps.js
index 5b40aaca..4987e50e 100644
--- a/src/ext/path-deps.js
+++ b/src/ext/path-deps.js
@@ -5,6 +5,9 @@
var _root = this;
function dependsOn(pathSpec, url) {
+ if (pathSpec === "ignore") {
+ return false;
+ }
var dependencyPath = pathSpec.split("/");
var urlPath = url.split("/");
for (var i = 0; i < urlPath.length; i++) {
@@ -35,7 +38,7 @@
if (name === "htmx:beforeOnLoad") {
var config = evt.detail.requestConfig;
// mutating call
- if (config.verb !== "get") {
+ if (config.verb !== "get" && evt.target.getAttribute('path-deps') !== 'ignore') {
refreshPath(config.path);
}
}