Skip to content

Commit 919230f

Browse files
committed
Add daily revalidation to TypeScript pages (#8456)
Added daily revalidation to TypeScript reference pages This PR adds a revalidation period of 24 hours (86400 seconds) to TypeScript reference pages to ensure content stays fresh while minimizing unnecessary rebuilds. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Chores** * Introduced daily automatic revalidation across multiple portal pages and layouts so content refreshes every 24 hours. This enables incremental static regeneration for affected pages, improving cache freshness and helping ensure users see up-to-date content with reduced stale data risk. <sub>✏️ Tip: You can customize this high-level summary in your review settings.</sub> <!-- end of auto-generated comment: release notes by coderabbit.ai --> <!-- start pr-codex --> --- ## PR-Codex overview This PR introduces a `revalidate` constant set to `86400` seconds (1 day) in multiple files, which specifies that the cached data should be revalidated every day. ### Detailed summary - Added `export const revalidate = 86400; // revalidate every day` to: - `apps/portal/src/app/contracts/extensions/page.tsx` - `apps/portal/src/app/react/v5/[...slug]/page.tsx` - `apps/portal/src/app/contracts/layout.tsx` - `apps/portal/src/app/typescript/v5/[...slug]/page.tsx` - `apps/portal/src/app/react/v5/layout.tsx` - `apps/portal/src/app/typescript/v5/layout.tsx` - `apps/portal/src/app/references/typescript/[version]/[[...slug]]/page.tsx` > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex -->
1 parent 3ac8cba commit 919230f

File tree

7 files changed

+14
-0
lines changed

7 files changed

+14
-0
lines changed

apps/portal/src/app/contracts/extensions/page.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,3 +77,5 @@ export default async function ExtensionPage() {
7777
</>
7878
);
7979
}
80+
81+
export const revalidate = 86400; // revalidate every day

apps/portal/src/app/contracts/layout.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,5 @@ export const metadata = createMetadata({
1919
},
2020
title: "Contracts",
2121
});
22+
23+
export const revalidate = 86400; // revalidate every day

apps/portal/src/app/react/v5/[...slug]/page.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,3 +27,5 @@ export default async function Page(props: PageProps) {
2727

2828
notFound();
2929
}
30+
31+
export const revalidate = 86400; // revalidate every day

apps/portal/src/app/react/v5/layout.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,3 +20,5 @@ export const metadata = createMetadata({
2020
"A type-safe library to interact with any EVM-compatible blockchain in React applications.",
2121
title: "thirdweb React SDK",
2222
});
23+
24+
export const revalidate = 86400; // revalidate every day

apps/portal/src/app/references/typescript/[version]/[[...slug]]/page.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,5 @@ const config = getTDocPage({
1414
export default config.default;
1515
export const generateStaticParams = config.generateStaticParams;
1616
export const generateMetadata = config.generateMetadata;
17+
18+
export const revalidate = 86400; // revalidate every day

apps/portal/src/app/typescript/v5/[...slug]/page.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,5 @@ export default async function Page(props: PageProps) {
2828

2929
notFound();
3030
}
31+
32+
export const revalidate = 86400; // revalidate every day

apps/portal/src/app/typescript/v5/layout.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,3 +20,5 @@ export const metadata = createMetadata({
2020
"A type-safe library to interact with any EVM-compatible blockchain in Node, web and native applications.",
2121
title: "thirdweb TypeScript SDK",
2222
});
23+
24+
export const revalidate = 86400; // revalidate every day

0 commit comments

Comments
 (0)