diff options
| author | Ariel Costas Guerrero <94913521+arielcostas@users.noreply.github.com> | 2025-01-20 13:39:52 +0100 |
|---|---|---|
| committer | Ariel Costas Guerrero <94913521+arielcostas@users.noreply.github.com> | 2025-01-20 13:39:52 +0100 |
| commit | 2b13e3d12cac732500ab1364358b33eeff9d361d (patch) | |
| tree | 03fb447eb73837fcb43b0776d2b0e49d8f26f11e /src/layouts | |
| parent | a20afcb783cece9496240a9444855f1475dc4244 (diff) | |
Fix canonical URLs with .html extension
Diffstat (limited to 'src/layouts')
| -rw-r--r-- | src/layouts/Layout.astro | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/layouts/Layout.astro b/src/layouts/Layout.astro index e1ab283..6eff088 100644 --- a/src/layouts/Layout.astro +++ b/src/layouts/Layout.astro @@ -19,7 +19,7 @@ const { title, description } = Astro.props; <meta name="description" content={description} /> <meta name="viewport" content="width=device-width" /> - <link rel="canonical" href={Astro.url} /> + <link rel="canonical" href={Astro.url.toString().replace(/\.html$/, '')} /> <link rel="alternate" type="application/rss+xml" href="/blog.xml" /> <link rel="sitemap" type="application/xml" href="/sitemap-index.xml" /> |
