Added new frontend.
This commit is contained in:
1 parent
8005b38b67
commit
9ada7cc1a8
30 files changed
+6620
-1
No files matched your search
@@ -0,0 +1,11 @@
|
||||
htmx.defineExtension('path-params', {
|
||||
onEvent: function(name, evt) {
|
||||
if (name === "htmx:configRequest") {
|
||||
evt.detail.path = evt.detail.path.replace(/{([^}]+)}/g, function (_, param) {
|
||||
var val = evt.detail.parameters[param];
|
||||
delete evt.detail.parameters[param];
|
||||
return val === undefined ? "{" + param + "}" : encodeURIComponent(val);
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
Reference in new issue
Block a user