Skip to content

Commit b9b115e

Browse files
committed
feat: add RSS Feed for /release-notes
1 parent 9a4ad2f commit b9b115e

File tree

5 files changed

+391
-126
lines changed

5 files changed

+391
-126
lines changed

.eleventy.js

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
const { EleventyHtmlBasePlugin } = require("@11ty/eleventy");
2+
const feedPlugin = require("@11ty/eleventy-plugin-rss");
23

34
const BROWSER_BUG_TRACKERS = {
45
chrome: "issues.chromium.org",
@@ -122,7 +123,7 @@ function augmentFeatureData(id, feature, bcd) {
122123
// Find the BCD entry for this key.
123124
const keyParts = key.split(".");
124125
bcdTags.push(keyParts[0] === "javascript" ? "js" : keyParts[0]);
125-
126+
126127
let data = bcd;
127128
for (const part of keyParts) {
128129
if (!data || !data[part]) {
@@ -204,7 +205,6 @@ async function getDeps() {
204205
module.exports = function (eleventyConfig) {
205206
eleventyConfig.addPlugin(EleventyHtmlBasePlugin);
206207
eleventyConfig.addPassthroughCopy("site/assets");
207-
208208
eleventyConfig.addShortcode(
209209
"browserVersionRelease",
210210
function (browser, version) {
@@ -354,6 +354,7 @@ module.exports = function (eleventyConfig) {
354354
month: "long",
355355
year: "numeric",
356356
}),
357+
absoluteDate: new Date(month[0]),
357358
all: [...month[1].all],
358359
features: month[1],
359360
};
@@ -476,6 +477,10 @@ module.exports = function (eleventyConfig) {
476477
return missingOne;
477478
});
478479

480+
// RSS Feed Plugin
481+
eleventyConfig.addPlugin(feedPlugin);
482+
eleventyConfig.addLiquidFilter("dateToRfc3339", feedPlugin.dateToRfc3339);
483+
479484
return {
480485
dir: {
481486
input: "site",

0 commit comments

Comments
 (0)