Skip to content

Commit 84dd869

Browse files
committed
Updates
1 parent 581cde4 commit 84dd869

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

src/components/ResourcesBySelector.astro

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -55,11 +55,11 @@ const filteredResources = [...docs, ...videos, ...learningPaths].filter(
5555
(tags ? data.tags?.some((v: string) => tags.includes(v)) : true) &&
5656
(products
5757
? data.products?.some((v) =>
58-
products.some((p) => p.id === (typeof v === "object" ? v.id : v)),
58+
products.some((p) => p.id === (typeof v === "object" ? v.id : v))
5959
)
6060
: true)
6161
);
62-
},
62+
}
6363
);
6464
6565
// Enhance resources with resolved product titles
@@ -77,7 +77,7 @@ const resources = await Promise.all(
7777
const productTitles = productEntries.map((p) => {
7878
if (p === undefined) {
7979
throw new Error(
80-
`Product value was not found. Check the filenames defined at https://github.com/cloudflare/cloudflare-docs/tree/production/src/content/products to make sure they match what's defined in your frontmatter.products field.`,
80+
`Product value was not found. Check the filenames defined at https://github.com/cloudflare/cloudflare-docs/tree/production/src/content/products to make sure they match what's defined in your frontmatter.products field.`
8181
);
8282
}
8383
return p.data.name as string;
@@ -90,7 +90,7 @@ const resources = await Promise.all(
9090
productTitles,
9191
},
9292
};
93-
}),
93+
})
9494
);
9595
9696
// Check for duplicate IDs
@@ -107,13 +107,13 @@ for (const resource of resources) {
107107
108108
if (duplicateIds.length > 0) {
109109
throw new Error(
110-
`[ResourcesBySelector] Found duplicate resource IDs: ${duplicateIds.join(", ")}`,
110+
`[ResourcesBySelector] Found duplicate resource IDs: ${duplicateIds.join(", ")}`
111111
);
112112
}
113113
114114
if (resources.length === 0) {
115115
throw new Error(
116-
`[ResourcesBySelector] Couldn't resources related to your filtered options`,
116+
`[ResourcesBySelector] Couldn't find resources related to your filtered options`
117117
);
118118
}
119119
@@ -139,7 +139,7 @@ const facets = resources.reduce(
139139
140140
return acc;
141141
},
142-
{} as Record<string, string[]>,
142+
{} as Record<string, string[]>
143143
);
144144
---
145145

src/content/docs/cache/how-to/cache-rules/examples/browser-cache-ttl.mdx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ pcx_content_type: example
33
summary: Browser Cache TTL
44
title: Browser Cache TTL
55
description: Browser Cache TTL
6+
products: [cache-rules]
67
---
78

89
import { Example, Render } from "~/components";

0 commit comments

Comments
 (0)