Add: htmx debug extension
This commit is contained in:
parent
aa7bb0b2b0
commit
787ba6d50f
2 changed files with 18 additions and 0 deletions
11
archivist/static/libs/htmx/debug.js
Normal file
11
archivist/static/libs/htmx/debug.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
htmx.defineExtension('debug', {
|
||||
onEvent: function (name, evt) {
|
||||
if (console.debug) {
|
||||
console.debug(name, evt);
|
||||
} else if (console) {
|
||||
console.log("DEBUG:", name, evt);
|
||||
} else {
|
||||
throw "NO CONSOLE SUPPORTED"
|
||||
}
|
||||
}
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue