Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions app/sitemap.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ function contentEntries(folder: 'blog' | 'guides', priority: number): MetadataRo
})
}

// Rebuilt hourly so a new DSOC project appears without a deploy
export const revalidate = 3600

// Built once per deploy, on purpose. Posts and guides are read from the content
// folder, which exists while the site is built but not where pages are rendered
// later, so a sitemap rebuilt on a timer loses them.
export default async function sitemap(): Promise<MetadataRoute.Sitemap> {
// Static pages carry no lastModified: claiming every page changed "now" on each
// build tells search engines nothing. Posts and guides use their real dates.
Expand Down
2 changes: 2 additions & 0 deletions next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ const nextConfig = {
outputFileTracingIncludes: {
'/agent-markdown': ['./content/blog/**/*.md', './content/guides/**/*.md'],
'/llms-full.txt': ['./content/blog/**/*.md', './content/guides/**/*.md'],
// Belt and braces: the sitemap is built at deploy time, but must never lose its posts
'/sitemap.xml': ['./content/blog/**/*.md', './content/guides/**/*.md'],
},
images: {
remotePatterns: [
Expand Down
Loading