Changing to new head structure.

This commit is contained in:
2023-02-14 06:55:58 -08:00
parent 5d7e0398ae
commit 1e2932bd93
19 changed files with 165 additions and 200 deletions

View File

@@ -1,9 +0,0 @@
import StandardHead from '@/components/StandardHead';
export default async function Head({ params }) {
return (
<StandardHead
title="Should you use Redux with React? — The React Show"
/>
);
};

View File

@@ -1,5 +1,9 @@
import { Article, H2, P } from '@/components/Components';
export const metadata = {
title: 'Should you use Redux with React?'
};
export default function Page() {
return (
<Article

View File

@@ -1,9 +0,0 @@
import StandardHead from '@/components/StandardHead';
export default async function Head({ params }) {
return (
<StandardHead
title="How React Renders Component Trees and How To Make It Faster — The React Show"
/>
);
};

View File

@@ -5,6 +5,10 @@ import { Article, H2, P, A } from '@/components/Components';
import renderTreeFlow from '@/images/render-tree-flow.gif';
import renderTreeMemo from '@/images/render-tree-memo.gif';
export const metadata = {
title: 'How React Renders Component Trees and How To Make It Faster'
};
export default function Page() {
return (
<Article

View File

@@ -1,9 +0,0 @@
import StandardHead from '@/components/StandardHead';
export default async function Head({ params }) {
return (
<StandardHead
title="White-labeling with React — The React Show"
/>
);
};

View File

@@ -1,5 +1,9 @@
import { Article, H2, P, A } from '@/components/Components';
export const metadata = {
title: 'White-labeling with React'
};
export default function Page() {
return (
<Article

View File

@@ -1,5 +1,10 @@
import Episodes from '@/components/Episodes'
export const metadata = {
title: 'All Episodes',
description: 'List of all episodes for The React Show.'
};
export default async function AllEpisodes() {
return (
<Episodes />

View File

@@ -1,10 +0,0 @@
import StandardHead from '@/components/StandardHead';
export default function Head({ params }) {
return (
<StandardHead
title="The React Show - Weekly React Focused Podcast"
description="Weekly podcast focused on React, programming, and software engineering."
/>
);
}

View File

@@ -61,6 +61,10 @@ function Loading() {
);
}
export const metadata = {
description: "Weekly podcast focused on React, programming, and software engineering."
};
export default async function Home() {
return (
<>

View File

@@ -1,13 +0,0 @@
import { getEpisode } from '@/data/episodes'
import StandardHead from '@/components/StandardHead';
export default async function Head({ params }) {
const episode = await getEpisode({ episodeSlug: params.slug })
return (
<StandardHead
title={`${episode.title} - The React Show`}
description={episode.description}
/>
);
};

View File

@@ -90,6 +90,14 @@ async function TranscriptWithPlayer({ episode }) {
)
};
export async function generateMetadata({ params }) {
const episode = await getEpisode({ episodeSlug: params.slug });
return {
title: episode.title,
description: `Podcast episode: ${episode.description}`
};
};
export default async function Page({ params }) {
const episode = await getEpisode({ episodeSlug: params.slug })
let date = new Date(episode.published)