Skip to content

Commit

Permalink
Add rss feed
Browse files Browse the repository at this point in the history
  • Loading branch information
Ovler-Young committed Sep 15, 2023
1 parent b530208 commit 26e5ba5
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,18 @@ const config = {
// Remove this to remove the "edit this page" links.
editUrl:
'https://github.com/buctsnc/docs/tree/main/',
feedOptions: {
type: 'all',
copyright: `Copyright © ${new Date().getFullYear()} BUCTSNC.`,
createFeedItems: async (params) => {
const {blogPosts, defaultCreateFeedItems, ...rest} = params;
return defaultCreateFeedItems({
// keep only the 20 most recent blog posts in the feed
blogPosts: blogPosts.filter((item, index) => index < 20),
...rest,
});
},
},
},
theme: {
customCss: require.resolve('./src/css/custom.css'),
Expand Down

0 comments on commit 26e5ba5

Please sign in to comment.