Skip to content

Commit 5066a12

Browse files
swAdd rss feed to the website.
1 parent c2c5314 commit 5066a12

File tree

12 files changed

+4636
-1762
lines changed

12 files changed

+4636
-1762
lines changed

docusaurus.config.ts

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ const config: Config = {
2020
organizationName: "/HaudinFlorence/", // Usually your GitHub org/user name.
2121
projectName: "quantstack.github.io", // Usually your repo name.
2222

23-
onBrokenLinks: "throw",
23+
onBrokenLinks: "warn",
2424
onBrokenMarkdownLinks: "warn",
2525
staticDirectories: ["static"],
2626

@@ -52,6 +52,7 @@ const config: Config = {
5252
},
5353
theme: {
5454
customCss: "./src/css/custom.css",
55+
5556
},
5657
} satisfies Preset.Options,
5758
],
@@ -61,6 +62,17 @@ const config: Config = {
6162
// Replace with your project's social card
6263
//image: 'img/docusaurus-social-card.jpg',
6364
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
65+
headTags: [
66+
{
67+
tagName: 'link',
68+
attributes: {
69+
rel: 'alternate',
70+
type: 'application/rss+xml',
71+
title: 'RSS Feed',
72+
href: '/rss.xml',
73+
},
74+
},
75+
],
6476
navbar: {
6577
title: "",
6678
logo: {
@@ -99,13 +111,22 @@ const config: Config = {
99111
label: "Blog",
100112
position: "left",
101113
},
114+
{
115+
label: 'RSS',
116+
href: 'rss.xml',
117+
position: 'left',
118+
target: '_blank',
119+
rel: 'noopener noreferrer',
120+
},
102121
{
103122
to: "/contact/",
104123
label: "CONTACT US",
105124
position: "right",
106125
className: "contact",
107126
},
108127

128+
129+
109130
{
110131
to: "https://github.com/QuantStack",
111132
title: "GitHub",

package-lock.json

Lines changed: 38 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
"docusaurus": "docusaurus",
1212
"start": "docusaurus start",
1313
"build": "docusaurus build",
14+
"prebuild": "node scripts/generate-rss-feed.js",
1415
"swizzle": "docusaurus swizzle",
1516
"deploy": "docusaurus deploy",
1617
"clear": "docusaurus clear",
@@ -48,6 +49,7 @@
4849
"react-slick": "^0.30.2",
4950
"reactjs-popup": "^2.0.6",
5051
"request": "^2.88.2",
52+
"rss": "^1.2.2",
5153
"slick-carousel": "^1.8.1"
5254
},
5355
"devDependencies": {

scripts/generate-rss-feed.js

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
const fs = require('fs');
2+
const RSS = require('rss');
3+
const { blogpostsDetails } = require('../src/components/blog/blogpostsDetails.js');
4+
const path = require('path');
5+
6+
const outputDir = path.join(process.cwd(), 'static');
7+
if (!fs.existsSync(outputDir)) {
8+
fs.mkdirSync(outputDir, { recursive: true });
9+
}
10+
11+
const feed = new RSS({
12+
title: 'Blog posts featured by QuantStack team',
13+
description: 'RSS feed for QuantStack website blog page',
14+
feed_url: 'https://quantstack.net/rss.xml',
15+
site_url: 'https://quantstack.net',
16+
language: 'en',
17+
});
18+
const posts = [];
19+
const nbOfBlogposts = blogpostsDetails.length;
20+
for (let i = 0; i < 10; i++) {
21+
const post = blogpostsDetails[i];
22+
console.log(post.title)
23+
const imagePath = 'https://quantstack.net' + '/' + post.image;
24+
console.log('imagePath:', imagePath)
25+
posts.push({
26+
title: post.title,
27+
description: post.summary,
28+
date: post.date,
29+
authors: post.authors,
30+
url: post.url,
31+
image: post.image,
32+
enclosure: {
33+
url: 'https://quantstack.net' + post.image,
34+
type: 'image/png', // or 'image/png', etc.
35+
length: 0, // optional, but required by some validators
36+
},
37+
})
38+
};
39+
40+
posts.forEach((post) => {
41+
feed.item({
42+
title: post.title,
43+
description: post.description,
44+
url: post.url,
45+
date: post.date,
46+
});
47+
});
48+
49+
fs.writeFileSync(path.join(outputDir, 'rss.xml'), feed.xml({ indent: true }));

scripts/static/rss.xml

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0">
2+
<channel>
3+
<title><![CDATA[Blog posts featured by QuantStack team]]></title>
4+
<description><![CDATA[RSS feed for QuantStack website blog page]]></description>
5+
<link>https://quantstack.net</link>
6+
<generator>RSS for Node</generator>
7+
<lastBuildDate>Mon, 23 Jun 2025 16:11:35 GMT</lastBuildDate>
8+
<atom:link href="https://quantstack.net/rss.xml" rel="self" type="application/rss+xml"/>
9+
<language><![CDATA[en]]></language>
10+
<item>
11+
<title><![CDATA[JupyterLite 0.6.0 is released! 🎉]]></title>
12+
<description><![CDATA[The new 0.6.0 release includes a number of new features, bug fixes, and enhancements. This release also brings significant improvements to the user experience and new customization options for JupyterLite deployments.]]></description>
13+
<link>https://blog.jupyter.org/jupyterlite-0-6-0-is-released-b4bc69bfc8f4</link>
14+
<guid isPermaLink="true">https://blog.jupyter.org/jupyterlite-0-6-0-is-released-b4bc69bfc8f4</guid>
15+
<pubDate>Wed, 11 Jun 2025 22:00:00 GMT</pubDate>
16+
</item>
17+
<item>
18+
<title><![CDATA[JupyterLab 4.4 and Notebook 7.4 are available!]]></title>
19+
<description><![CDATA[JupyterLab 4.4 has been released! This new minor release of JupyterLab includes 28 new features and enhancements, 76 bug fixes, 63 maintenance tasks and 34 documentation improvements.]]></description>
20+
<link>https://blog.jupyter.org/jupyterlab-4-4-and-notebook-7-4-are-available-aca2782d4f3d</link>
21+
<guid isPermaLink="true">https://blog.jupyter.org/jupyterlab-4-4-and-notebook-7-4-are-available-aca2782d4f3d</guid>
22+
<pubDate>Tue, 20 May 2025 22:00:00 GMT</pubDate>
23+
</item>
24+
<item>
25+
<title><![CDATA[Congratulations, Distinguished Contributors!]]></title>
26+
<description><![CDATA[We are proud to announce the recipients of the Jupyter Distinguished Contributor (JDC) award for the 2024 cohort of contributors.]]></description>
27+
<link>https://blog.jupyter.org/congratulations-distinguished-contributors-2504029fc5a9</link>
28+
<guid isPermaLink="true">https://blog.jupyter.org/congratulations-distinguished-contributors-2504029fc5a9</guid>
29+
<pubDate>Wed, 14 May 2025 22:00:00 GMT</pubDate>
30+
</item>
31+
<item>
32+
<title><![CDATA[Making Qt collaborative using CRDTs]]></title>
33+
<description><![CDATA[A journal on creating a collaborative application with Qt]]></description>
34+
<link>https://david-brochart.medium.com/making-qt-collaborative-using-crdts-94c470703253</link>
35+
<guid isPermaLink="true">https://david-brochart.medium.com/making-qt-collaborative-using-crdts-94c470703253</guid>
36+
<pubDate>Sun, 30 Mar 2025 22:00:00 GMT</pubDate>
37+
</item>
38+
<item>
39+
<title><![CDATA[R in the Browser: Announcing Our WebAssembly Distribution]]></title>
40+
<description><![CDATA[R is now available in emscripten-forge, enabling the Xeus-R kernel in JupyterLite.]]></description>
41+
<link>https://blog.jupyter.org/r-in-the-browser-announcing-our-webassembly-distribution-9450e9539ed5</link>
42+
<guid isPermaLink="true">https://blog.jupyter.org/r-in-the-browser-announcing-our-webassembly-distribution-9450e9539ed5</guid>
43+
<pubDate>Thu, 27 Feb 2025 23:00:00 GMT</pubDate>
44+
</item>
45+
<item>
46+
<title><![CDATA[Real-time collaboration and collaborative editing for GIS workflows with Jupyter and QGIS]]></title>
47+
<description><![CDATA[We are excited to announce JupyterGIS, a web-based, collaborative, and extensible interface for GIS, leveraging the JupyterLab application framework and integrating seamlessly with the Jupyter notebook interface.]]></description>
48+
<link>https://blog.jupyter.org/real-time-collaboration-and-collaborative-editing-for-gis-workflows-with-jupyter-and-qgis-d25dbe2832a6</link>
49+
<guid isPermaLink="true">https://blog.jupyter.org/real-time-collaboration-and-collaborative-editing-for-gis-workflows-with-jupyter-and-qgis-d25dbe2832a6</guid>
50+
<pubDate>Tue, 25 Feb 2025 23:00:00 GMT</pubDate>
51+
</item>
52+
<item>
53+
<title><![CDATA[PyData Paris 2025 Keynotes]]></title>
54+
<description><![CDATA[We are thrilled to announce the keynote speakers for the upcoming PyData Paris 2025, the leading gathering of the open-source data science and AI/ML community in France.]]></description>
55+
<link>https://medium.com/@PyDataParis/pydata-paris-2025-50ff2bf2dc39</link>
56+
<guid isPermaLink="true">https://medium.com/@PyDataParis/pydata-paris-2025-50ff2bf2dc39</guid>
57+
<pubDate>Tue, 18 Feb 2025 23:00:00 GMT</pubDate>
58+
</item>
59+
<item>
60+
<title><![CDATA[Announcing JupyterCAD 3.0]]></title>
61+
<description><![CDATA[We are thrilled to introduce JupyterCAD 3.0, the newest version of the collaborative CAD modeler designed for JupyterLab.]]></description>
62+
<link>https://blog.jupyter.org/announcing-jupytercad-3-0-d8f4b7b0a719</link>
63+
<guid isPermaLink="true">https://blog.jupyter.org/announcing-jupytercad-3-0-d8f4b7b0a719</guid>
64+
<pubDate>Sun, 16 Feb 2025 23:00:00 GMT</pubDate>
65+
</item>
66+
<item>
67+
<title><![CDATA[Sparrow]]></title>
68+
<description><![CDATA[We are thrilled to introduce Sparrow, a new library designed to simplify the integration of Apache Arrow’s columnar format into C++ applications.]]></description>
69+
<link>https://johan-mabille.medium.com/sparrow-1f23817f6696</link>
70+
<guid isPermaLink="true">https://johan-mabille.medium.com/sparrow-1f23817f6696</guid>
71+
<pubDate>Thu, 30 Jan 2025 23:00:00 GMT</pubDate>
72+
</item>
73+
<item>
74+
<title><![CDATA[JupyterLite Terminal]]></title>
75+
<description><![CDATA[QuantStack are delighted to announce that we have been working on a new Terminal for JupyterLite.]]></description>
76+
<link>https://blog.jupyter.org/jupyterlite-terminal-edb3f80dc1c0</link>
77+
<guid isPermaLink="true">https://blog.jupyter.org/jupyterlite-terminal-edb3f80dc1c0</guid>
78+
<pubDate>Tue, 12 Nov 2024 23:00:00 GMT</pubDate>
79+
</item>
80+
</channel>
81+
</rss>

0 commit comments

Comments
 (0)