diff options
| author | William Hergès <william@herges.fr> | 2025-10-03 17:21:29 +0200 |
|---|---|---|
| committer | William Hergès <william@herges.fr> | 2025-10-03 17:21:29 +0200 |
| commit | 270f592fc65cd5553ccf7c0dc81431c3efdf67ab (patch) | |
| tree | 4c1c53f3c40b6324201dda10a8c30c7438fcbde7 /index.ts | |
| parent | ed216fcfbd19d97f35292ceb9af77aab989446b0 (diff) | |
feat(frontend): bundle htmx and set every external link to target blank
Diffstat (limited to 'index.ts')
| -rw-r--r-- | index.ts | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -1 +1,6 @@ -console.log("Hello via Bun!");
\ No newline at end of file +import 'htmx.org'; + +document.querySelectorAll("a").forEach(e => { + if (e.href.startsWith(window.location.origin)) return; + e.target = "_blank"; +}); |
