Skip to content

Commit 7eae74c

Browse files
committed
disable header caching temporarily
1 parent 144b2bf commit 7eae74c

File tree

3 files changed

+13
-13
lines changed

3 files changed

+13
-13
lines changed

app/routes/_libraries/blog.$.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,10 @@ const fetchBlogPost = createServerFn({ method: 'GET' })
3030
const frontMatter = extractFrontMatter(file)
3131
const description = removeMarkdown(frontMatter.excerpt ?? '')
3232

33-
setHeaders({
34-
'cache-control': 'public, max-age=0, must-revalidate',
35-
'cdn-cache-control': 'max-age=300, stale-while-revalidate=300, durable',
36-
})
33+
// setHeaders({
34+
// 'cache-control': 'public, max-age=0, must-revalidate',
35+
// 'cdn-cache-control': 'max-age=300, stale-while-revalidate=300, durable',
36+
// })
3737

3838
return {
3939
title: frontMatter.data.title,

app/routes/_libraries/blog.index.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,11 @@ const fetchFrontMatters = createServerFn({ method: 'GET' }).handler(
3030

3131
const frontMatter = extractFrontMatter(file)
3232

33-
setHeaders({
34-
'cache-control': 'public, max-age=0, must-revalidate',
35-
'cdn-cache-control':
36-
'max-age=300, stale-while-revalidate=300, durable',
37-
})
33+
// setHeaders({
34+
// 'cache-control': 'public, max-age=0, must-revalidate',
35+
// 'cdn-cache-control':
36+
// 'max-age=300, stale-while-revalidate=300, durable',
37+
// })
3838

3939
return [
4040
info.id,

app/utils/config.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,10 @@ export const getTanstackDocsConfig = createServerFn({ method: 'GET' })
7474
throw new Error('Zod validation failed')
7575
}
7676

77-
setHeaders({
78-
'cache-control': 'public, max-age=0, must-revalidate',
79-
'cdn-cache-control': 'max-age=300, stale-while-revalidate=300, durable',
80-
})
77+
// setHeaders({
78+
// 'cache-control': 'public, max-age=0, must-revalidate',
79+
// 'cdn-cache-control': 'max-age=300, stale-while-revalidate=300, durable',
80+
// })
8181

8282
return validationResult.data
8383
} catch (e) {

0 commit comments

Comments
 (0)