From 1e15a382a1363ab7de3a84755dbfcd107db883ac Mon Sep 17 00:00:00 2001 From: KazooTTT Date: Sat, 23 Nov 2024 21:47:33 +0800 Subject: [PATCH] feat: add slug console --- src/components/layout/Footer.astro | 1 + 1 file changed, 1 insertion(+) diff --git a/src/components/layout/Footer.astro b/src/components/layout/Footer.astro index 927178b..0e352e2 100644 --- a/src/components/layout/Footer.astro +++ b/src/components/layout/Footer.astro @@ -5,6 +5,7 @@ import PageViews from '../PageViews' const pathname = new URL(Astro.request.url).pathname const isBlogPost = pathname.startsWith('/blog/') && pathname !== '/blog' const slug = pathname === '/' ? 'home' : pathname.replace(/^\/|\/$/g, '') +console.log('Slug:', slug) ---