Skip to content

Commit ab281d6

Browse files
fix: 404 and descriptions (#2830)
<!-- Please make sure there is an issue that this PR is correlated to. --> ## Changes <!-- If there are frontend changes, please include screenshots. -->
1 parent 32ac342 commit ab281d6

File tree

8 files changed

+139
-4
lines changed

8 files changed

+139
-4
lines changed

site/next.config.ts

Lines changed: 109 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,73 @@ const nextConfig = {
2626
return [
2727
// Next.js redirects for Cloudflare deployment
2828

29+
// Permanent redirects for common 404s
30+
{
31+
source: '/docs/config',
32+
destination: '/docs/cloud/config',
33+
permanent: true,
34+
},
35+
{
36+
source: '/discord',
37+
destination: 'https://discord.gg/aXYfyNxYVn',
38+
permanent: true,
39+
},
40+
{
41+
source: '/docs/functions',
42+
destination: '/docs/cloud/functions',
43+
permanent: true,
44+
},
45+
{
46+
source: '/docs/general/testing',
47+
destination: '/docs/actors/testing',
48+
permanent: true,
49+
},
50+
{
51+
source: '/docs/local-development',
52+
destination: '/docs/cloud/local-development',
53+
permanent: true,
54+
},
55+
{
56+
source: '/actors/communicating-with-actors',
57+
destination: '/docs/actors/communicating-between-actors',
58+
permanent: true,
59+
},
60+
{
61+
source: '/docs/api',
62+
destination: '/docs/cloud/api',
63+
permanent: true,
64+
},
65+
{
66+
source: '/docs/troubleshooting',
67+
destination: '/docs/cloud/troubleshooting',
68+
permanent: true,
69+
},
70+
{
71+
source: '/docs/edge',
72+
destination: '/docs/general/edge',
73+
permanent: true,
74+
},
75+
{
76+
source: '/docs/edge/',
77+
destination: '/docs/general/edge',
78+
permanent: true,
79+
},
80+
{
81+
source: '/docs/durability',
82+
destination: '/docs/cloud/durability',
83+
permanent: true,
84+
},
85+
{
86+
source: '/clients/javascript',
87+
destination: '/docs/clients/javascript',
88+
permanent: true,
89+
},
90+
{
91+
source: '/docs/networking',
92+
destination: '/docs/cloud/networking',
93+
permanent: true,
94+
},
95+
2996
// Convenience Redirects
3097
{
3198
source: '/docs',
@@ -242,6 +309,48 @@ const nextConfig = {
242309
permanent: false,
243310
},
244311

312+
// Additional 404 fixes from SEO audit
313+
{
314+
source: '/docs/config/',
315+
destination: '/docs/cloud/config',
316+
permanent: true,
317+
},
318+
{
319+
source: '/docs/general/testing/',
320+
destination: '/docs/actors/testing',
321+
permanent: true,
322+
},
323+
{
324+
source: '/docs/local-development/',
325+
destination: '/docs/cloud/local-development',
326+
permanent: true,
327+
},
328+
{
329+
source: '/docs/api/',
330+
destination: '/docs/cloud/api',
331+
permanent: true,
332+
},
333+
{
334+
source: '/docs/troubleshooting/',
335+
destination: '/docs/cloud/troubleshooting',
336+
permanent: true,
337+
},
338+
{
339+
source: '/docs/durability/',
340+
destination: '/docs/cloud/durability',
341+
permanent: true,
342+
},
343+
{
344+
source: '/clients/javascript/',
345+
destination: '/docs/clients/javascript',
346+
permanent: true,
347+
},
348+
{
349+
source: '/docs/networking/',
350+
destination: '/docs/cloud/networking',
351+
permanent: true,
352+
},
353+
245354
];
246355
},
247356
webpack: (config) => {

site/src/app/(v2)/(marketing)/pricing/page.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,10 @@ import PricingPageClient from "./PricingPageClient";
44
export const metadata: Metadata = {
55
title: "Pricing - Rivet",
66
description:
7-
"See Rivet’s transparent pricing for serverless compute—billed by the millisecond for functions, actors, and containers. No hidden fees.",
7+
"See Rivet's transparent pricing for serverless compute—billed by the millisecond for functions, actors, and containers. No hidden fees.",
8+
alternates: {
9+
canonical: "https://www.rivet.gg/pricing/",
10+
},
811
};
912

1013
export default function Page() {

site/src/app/(v2)/(marketing)/sales/page.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ export const metadata: Metadata = {
55
title: "Enterprise Sales - Rivet",
66
description:
77
"Contact Rivet to discuss enterprise-grade serverless infrastructure for AI agents, realtime systems, and scalable function-based workloads",
8+
alternates: {
9+
canonical: "https://www.rivet.gg/sales/",
10+
},
811
};
912

1013
export default function SalesPage() {

site/src/app/(v2)/(marketing)/support/page.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ export const metadata: Metadata = {
55
title: "Support - Rivet",
66
description:
77
"Get help with Rivet, from troubleshooting to feature requests.",
8+
alternates: {
9+
canonical: "https://www.rivet.gg/support/",
10+
},
811
};
912

1013
export default function SupportPage() {

site/src/app/(v2)/(marketing)/talk-to-an-engineer/page.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ export const metadata: Metadata = {
55
title: "Talk to an Engineer - Rivet",
66
description:
77
"Connect with a Rivet engineer to discuss your technical needs, current stack, and how we can help with your infrastructure challenges",
8+
alternates: {
9+
canonical: "https://www.rivet.gg/talk-to-an-engineer/",
10+
},
811
};
912

1013
export default function TalkToAnEngineerPage() {

site/src/app/(v2)/[section]/[[...page]]/page.tsx

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,7 @@ async function loadContent(path: string[]) {
5656
};
5757
} catch (indexError) {
5858
if (indexError.code === "MODULE_NOT_FOUND") {
59-
throw new Error(
60-
`Content not found for path: ${path.join("/")}`,
61-
);
59+
return notFound();
6260
}
6361
throw indexError;
6462
}
@@ -75,9 +73,15 @@ export async function generateMetadata({
7573
component: { title, description },
7674
} = await loadContent(path);
7775

76+
const fullPath = buildFullPath(path);
77+
const canonicalUrl = `https://www.rivet.gg${fullPath}/`;
78+
7879
return {
7980
title: `${title} - Rivet`,
8081
description,
82+
alternates: {
83+
canonical: canonicalUrl,
84+
},
8185
};
8286
}
8387

site/src/content/docs/cloud/hub.mdx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
---
2+
title: "Hub"
3+
description: "Rivet Hub dashboard for managing your cloud infrastructure, monitoring actors, and viewing project analytics."
4+
---
5+
16
# Hub
27

38
- Logs

site/src/content/docs/cloud/limitations.mdx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
---
2+
title: "Limitations"
3+
description: "Rivet Cloud platform limits for actors, KV storage, builds, and tags. Contact support for limit increases on Team plans."
4+
---
5+
16
# Limitations
27

38
<Note>[Contact us](/support) if you need an increase.</Note>

0 commit comments

Comments
 (0)