aboutsummaryrefslogtreecommitdiff
path: root/frontend
diff options
context:
space:
mode:
Diffstat (limited to 'frontend')
-rw-r--r--frontend/index.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/frontend/index.ts b/frontend/index.ts
index 13997b3..ee1e7ae 100644
--- a/frontend/index.ts
+++ b/frontend/index.ts
@@ -2,7 +2,7 @@ import htmx from "htmx.org";
function setupAnchors() {
document.querySelectorAll("a").forEach(e => {
- if (!e.href.startsWith(window.location.origin)) {
+ if (!e.href.startsWith(window.location.origin) && /https?:\/\//.test(e.href)) {
e.target = "_blank";
return
}