From 4f07656602cbae569eecd8f7e3d013d934873062 Mon Sep 17 00:00:00 2001 From: Sean Wood Date: Fri, 24 Nov 2023 09:17:32 +0000 Subject: [PATCH] fix: treat "/" like any other absolute path --- src/Link.svelte | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Link.svelte b/src/Link.svelte index 00c3d3c..fd072bd 100755 --- a/src/Link.svelte +++ b/src/Link.svelte @@ -15,7 +15,7 @@ const dispatch = createEventDispatcher(); let href, isPartiallyCurrent, isCurrent, props; - $: href = to === "/" ? $base.uri : resolve(to, $base.uri); + $: href = resolve(to, $base.uri); $: isPartiallyCurrent = $location.pathname.startsWith(href); $: isCurrent = href === $location.pathname; $: ariaCurrent = isCurrent ? "page" : undefined;