Adds per-page titles, meta descriptions, and the design favicon
Introduces pageHead() and siteHead in seo.ts for title, description, and Open Graph tags, rendered through TanStack Router's HeadContent. Home and Over mij get their own title and description. index.html now uses lang="nl" and carries fallback tags for crawlers without JavaScript; main.tsx removes them on startup to avoid duplicates. Replaces the Vite favicon with the design's favicon.png (also as apple-touch-icon). Remaining SEO work is tracked in Gitea issue #1. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit was merged in pull request #2.
This commit is contained in:
@@ -1,12 +1,18 @@
|
||||
import { createRootRoute } from '@tanstack/react-router';
|
||||
import { createRootRoute, HeadContent } from '@tanstack/react-router';
|
||||
import { TanStackRouterDevtools } from '@tanstack/react-router-devtools';
|
||||
import AppShell from '../components/AppShell';
|
||||
import { siteHead } from '../seo';
|
||||
|
||||
const RootLayout = () => (
|
||||
<>
|
||||
{/* Titel en meta-tags van de actieve route; React zet ze in <head> */}
|
||||
<HeadContent />
|
||||
<AppShell />
|
||||
<TanStackRouterDevtools />
|
||||
</>
|
||||
);
|
||||
|
||||
export const Route = createRootRoute({ component: RootLayout });
|
||||
export const Route = createRootRoute({
|
||||
head: () => siteHead,
|
||||
component: RootLayout,
|
||||
});
|
||||
|
||||
@@ -1,8 +1,15 @@
|
||||
import { createFileRoute } from '@tanstack/react-router';
|
||||
import Hero from '../components/Hero/Hero';
|
||||
import heroContent from '../components/Hero/heroContent';
|
||||
import { pageHead } from '../seo';
|
||||
|
||||
export const Route = createFileRoute('/')({
|
||||
head: () =>
|
||||
pageHead({
|
||||
title: 'Lifestyle fotograaf in Huizen | Andrea Slop Fotografie',
|
||||
description:
|
||||
"Lifestyle fotograaf in Huizen en omgeving. Ik leg je mooiste momenten vast in spontane, kleurrijke foto's. Voor loveshoots, gezins- en zwangerschapsshoots.",
|
||||
}),
|
||||
component: Index,
|
||||
});
|
||||
|
||||
|
||||
@@ -1,6 +1,13 @@
|
||||
import { createFileRoute } from "@tanstack/react-router";
|
||||
import { pageHead } from "../seo";
|
||||
|
||||
export const Route = createFileRoute("/over-mij")({
|
||||
head: () =>
|
||||
pageHead({
|
||||
title: "Over mij | Andrea Slop Fotografie",
|
||||
description:
|
||||
"Hi! Ik ben Andrea, lifestyle fotograaf uit Huizen. Ik leg jullie vast zoals jullie zijn: spontaan en natuurlijk, zonder ongemakkelijke poses.",
|
||||
}),
|
||||
component: About,
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user