Skip to content

Commit a97cc9a

Browse files
committed
fix(sitemap): serve /sitemap as static redirect, kill React-side race
1 parent 8caae05 commit a97cc9a

4 files changed

Lines changed: 17 additions & 36 deletions

File tree

pages/routes.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,6 @@ export const staticRoutes = [
129129
"/reading",
130130
"/roadmap",
131131
"/settings",
132-
"/sitemap",
133132
"/stories",
134133
"/stories/authors",
135134
"/stories/characters",

public/sitemap/index.html

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="utf-8" />
5+
<title>Sitemap — Fezcodex</title>
6+
<meta http-equiv="refresh" content="0; url=/sitemap.xml" />
7+
<link rel="canonical" href="https://fezcode.com/sitemap.xml" />
8+
<meta name="robots" content="noindex" />
9+
<style>
10+
body { background: #0a0a0a; color: #f0f0f0; font-family: Georgia, serif; padding: 4rem 2rem; text-align: center; }
11+
a { color: #f0f0f0; }
12+
</style>
13+
</head>
14+
<body>
15+
<h1>Redirecting to <a href="/sitemap.xml">sitemap.xml</a></h1>
16+
</body>
17+
</html>

src/components/AnimatedRoutes.jsx

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,6 @@ const NotebookViewerPage = lazy(
239239
const CommandsPage = lazy(() => import('../pages/CommandsPage'));
240240
const AchievementsPage = lazy(() => import('../pages/AchievementsPage'));
241241
const VocabPage = lazy(() => import('../pages/VocabPage'));
242-
const SitemapPage = lazy(() => import('../pages/SitemapPage'));
243242
const WelcomePage = lazy(() => import('../pages/WelcomePage'));
244243
const DashboardPage = lazy(() => import('../pages/DashboardPage'));
245244
const KnowledgeGraphPage = lazy(() => import('../pages/KnowledgeGraphPage'));
@@ -870,22 +869,6 @@ const AnimatedRoutes = ({
870869
</motion.div>
871870
}
872871
/>
873-
<Route
874-
path="/sitemap"
875-
element={
876-
<motion.div
877-
initial="initial"
878-
animate="in"
879-
exit="out"
880-
variants={pageVariants}
881-
transition={pageTransition}
882-
>
883-
<Suspense fallback={<Loading />}>
884-
<SitemapPage />
885-
</Suspense>
886-
</motion.div>
887-
}
888-
/>
889872
<Route
890873
path="/welcome"
891874
element={

src/pages/SitemapPage.jsx

Lines changed: 0 additions & 18 deletions
This file was deleted.

0 commit comments

Comments
 (0)