feat: handle absolute internal links for stacked notes

This commit is contained in:
Julien Calixte
2026-02-19 21:32:37 +01:00
parent b14f5f1dc1
commit 801832c6e5
4 changed files with 42 additions and 19 deletions

View File

@@ -1,4 +1,5 @@
export const LINKS = ['http://', 'https://']
export const LINKS = ["http://", "https://"]
export const isExternalLink = (href: string) =>
!href.startsWith(window.location.origin) &&
LINKS.some((link) => href.startsWith(link))