File tree Expand file tree Collapse file tree 5 files changed +117
-0
lines changed
content/docs/fundamentals/changelog Expand file tree Collapse file tree 5 files changed +117
-0
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ import AnchorHeading from " ./AnchorHeading.astro" ;
3+ import RSSButton from " ./RSSButton.astro" ;
4+
5+ import { products , productsByGroup } from " ~/util/products" ;
6+ import Details from " ./Details.astro" ;
7+ ---
8+
9+ <AnchorHeading depth ={ 2 } title =" Feeds" />
10+
11+ <AnchorHeading depth ={ 3 } title =" Global feed" />
12+ <p >
13+ This feed contains entries for all Cloudflare products: <RSSButton />
14+
15+ <AnchorHeading depth ={ 3 } title =" Area-specific feeds" />
16+ {
17+ productsByGroup .map (([group , products ]) => (
18+ <>
19+ <AnchorHeading depth = { 4 } title = { group } />
20+ <p >
21+ This feed contains entries for all { group } products:{ " " }
22+ <RSSButton changelog = { group } />
23+ </p >
24+ <Details header = " Included products" >
25+ <ul >
26+ { products .map ((product ) => (
27+ <li >
28+ <p >
29+ <a href = { product .data .product .url } >
30+ { product .data .product .title }
31+ </a >
32+ </p >
33+ <RSSButton changelog = { product .id } />
34+ </li >
35+ ))}
36+ </ul >
37+ </Details >
38+ </>
39+ ))
40+ }
41+ </p >
Original file line number Diff line number Diff line change 1+ ---
2+ import { z } from " astro:schema" ;
3+ import { Icon } from " @astrojs/starlight/components" ;
4+
5+ const props = z .object ({
6+ changelog: z
7+ .string ()
8+ .transform ((val ) => val .toLowerCase ().replaceAll (" " , " -" ))
9+ .default (" index" ),
10+ });
11+
12+ const { changelog } = props .parse (Astro .props );
13+ ---
14+
15+ <a
16+ href ={ ` /changelog/rss/${changelog }.xml ` }
17+ class =" inline-flex items-center justify-center gap-1 rounded font-semibold no-underline"
18+ target =" _blank"
19+ >
20+ Subscribe to RSS
21+ <Icon name =" rss" size =" 1.25rem" />
22+ </a >
Original file line number Diff line number Diff line change 1+ ---
2+ title : Available RSS Feeds
3+ description : Read about the various RSS feeds available for Cloudflare's changelogs.
4+ ---
5+
6+ import AvailableChangelogFeeds from ' ~/components/AvailableChangelogFeeds.astro' ;
7+
8+ ## Consuming RSS Feeds
9+
10+ Our changelogs are published to various RSS feeds with HTML in the ` <description> ` tag.
11+
12+ In feeds with multiple products, such as the global or product-area feeds, the products associated with a given entry are in the ` <category> ` tag.
13+
14+ A single product will also appear in the custom ` <product> ` tag for legacy reasons, but we recommend you use the ` <category> `
15+
16+ ### Example XML
17+
18+ ``` xml
19+ <rss version =" 2.0" >
20+ <channel >
21+ <title >Cloudflare changelogs</title >
22+ <description >Updates to various Cloudflare products</description >
23+ <link >https://developers.cloudflare.com/changelog/</link >
24+ <item >
25+ <title >Agents, Workers, Workflows - Build AI Agents with Example Prompts</title >
26+ <link >https://developers.cloudflare.com/changelog/2025-02-14-example-ai-prompts/</link >
27+ <guid isPermaLink =" true" >https://developers.cloudflare.com/changelog/2025-02-14-example-ai-prompts/</guid >
28+ <description >
29+ <p >
30+ We've added an <a href =" https://developers.cloudflare.com/workers/get-started/prompting/" >example prompt</a > to help you get started with building AI agents and applications on Cloudflare ...
31+ </p >
32+ </description >
33+ <pubDate >Fri, 14 Feb 2025 19:00:00 GMT</pubDate >
34+ <product >Agents</product >
35+ <category >Agents</category >
36+ <category >Workers</category >
37+ <category >Workflows</category >
38+ </item >
39+ </channel >
40+ </rss >
41+ ```
42+
43+ <AvailableChangelogFeeds />
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ title: Changelog
44release_notes_file_name :
55 - fundamentals
66sidebar :
7+ label : Fundamentals
78 order : 9
89---
910
Original file line number Diff line number Diff line change 1+ import { getCollection } from "astro:content" ;
2+
3+ export const products = await getCollection ( "products" ) ;
4+
5+ export const productsByGroup = Object . entries (
6+ Object . groupBy (
7+ products . filter ( ( product ) => Boolean ( product . data . product . group ) ) ,
8+ ( product ) => product . data . product . group ,
9+ ) ,
10+ ) . sort ( ) ;
You can’t perform that action at this time.
0 commit comments