Skip to content
Open
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
15 changes: 12 additions & 3 deletions astro.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,11 @@ export default defineConfig({
integrations: [
trailingSlashMiddleware(),
preact({
include: ["**/preact/*"],
include: ["**/preact/**"],
}),
react({
include: ["**/react/*"],
include: ["**/*.tsx", "**/*.jsx"],
exclude: ["**/preact/**"],
}),
sitemap({
changefreq: "daily",
Expand Down Expand Up @@ -81,6 +82,12 @@ export default defineConfig({
const pathname = new URL(page).pathname
const cleanPath = pathname.endsWith("/") && pathname !== "/" ? pathname.slice(0, -1) : pathname

// Exclude markdown endpoints from sitemap.
// Keep them directly accessible, but do not publish them as canonical crawl targets.
if (cleanPath.endsWith(".md")) {
return false
}

// Exclude short format API reference URLs (e.g., /api-reference/v150, /ccip/api-reference/evm/v150)
// These are aliases for versioned content - we keep only the canonical long format URLs
const shortVersionPattern = /\/api-reference\/(?:.*\/)?v\d{3,4}(?:\/|$)/
Expand Down Expand Up @@ -130,7 +137,9 @@ export default defineConfig({
},
// output: 'static' (fully static or partial SSR with `prerender = false` ==> export const prerender = false;)
output: "static",
adapter: vercel(),
adapter: vercel({
edgeMiddleware: true,
}),
vite: {
plugins: [yaml()],
build: {
Expand Down
Loading
Loading