Skip to content

Commit

Permalink
Create blog feed with virtual template
Browse files Browse the repository at this point in the history
  • Loading branch information
helenclx committed Oct 4, 2024
1 parent 9efb97a commit cf2a956
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 30 deletions.
24 changes: 22 additions & 2 deletions eleventy.config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// Installed Plugins
import pluginRss from "@11ty/eleventy-plugin-rss";
import { feedPlugin } from "@11ty/eleventy-plugin-rss";
import pluginEleventyNavigation from "@11ty/eleventy-navigation";
import pluginSyntaxHighlight from "@11ty/eleventy-plugin-syntaxhighlight";
import pluginMetagen from "eleventy-plugin-metagen";
Expand All @@ -12,9 +12,29 @@ import collectionsConfig from "./src/_config/collections.js";
import filtersConfig from "./src/_config/filters.js";
import shortCodesConfig from "./src/_config/shortcodes.js";

// Sitemeta
import { } from "./src/_data/sitemeta.js";

export default function(eleventyConfig) {
// Installed Plugins
eleventyConfig.addPlugin(pluginRss);
eleventyConfig.addPlugin(feedPlugin, {
type: "atom",
outputPath: "/blog/feed.xml",
collection: {
name: "posts",
limit: 10,
},
metadata: {
language: "en",
title: "Helen Chong's Developer Blog",
subtitle: "Helen Chong talks about tech, coding and development.",
base: "https://helenchong.dev/blog/",
author: {
name: "Helen Chong",
email: "[email protected]",
}
}
});
eleventyConfig.addPlugin(pluginEleventyNavigation);
eleventyConfig.addPlugin(pluginSyntaxHighlight, { preAttributes: { tabindex: 0 } });
eleventyConfig.addPlugin(pluginMetagen);
Expand Down
28 changes: 0 additions & 28 deletions src/blog/feed.njk

This file was deleted.

0 comments on commit cf2a956

Please sign in to comment.