fix(www): send the docs logo and site root to the docs home (#58451)

This commit is contained in:
Filip
2026-10-23 14:37:34 +02:00
committed by GitHub
Unverified
parent 5ffc418fbd
commit 02671e6645
2 changed files with 4 additions and 16 deletions
@@ -12,7 +12,7 @@ const searchEnabled = import.meta.env.PROD
<header class="site-header">
<div class="header-inner">
<a class="brand" href={import.meta.env.BASE_URL} aria-label="OpenCode home">
<a class="brand" href={docsHref("index")} aria-label="OpenCode docs home">
<img class="logo-dark" src={`${import.meta.env.BASE_URL}assets/logo-dark.svg`} alt="OpenCode" />
<img class="logo-light" src={`${import.meta.env.BASE_URL}assets/logo-light.svg`} alt="OpenCode" />
</a>
+3 -15
View File
@@ -1,17 +1,5 @@
---
export const prerender = true
const destination = `${import.meta.env.BASE_URL}docs`
---
export const prerender = false
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta http-equiv="refresh" content={`0; url=${destination}`} />
<link rel="canonical" href={destination} />
<title>OpenCode Docs</title>
</head>
<body>
<a href={destination}>Continue to the OpenCode docs</a>
</body>
</html>
return Astro.redirect(`${import.meta.env.BASE_URL}docs/`, 301)
---