mirror of
https://github.com/tcsenpai/obsidiangarden_netlify.git
synced 2025-06-06 20:55:21 +00:00
Fix RSS feed #136
This commit is contained in:
parent
a02bfd53b7
commit
d7dca4e45f
14
.eleventy.js
14
.eleventy.js
@ -398,12 +398,7 @@ module.exports = function (eleventyConfig) {
|
|||||||
ul: true,
|
ul: true,
|
||||||
tags: ["h1", "h2", "h3", "h4", "h5", "h6"],
|
tags: ["h1", "h2", "h3", "h4", "h5", "h6"],
|
||||||
});
|
});
|
||||||
eleventyConfig.addPlugin(pluginRss, {
|
|
||||||
posthtmlRenderOptions: {
|
|
||||||
closingSingleTag: "slash",
|
|
||||||
singleTags: ["link"],
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
eleventyConfig.addFilter("dateToZulu", function (date) {
|
eleventyConfig.addFilter("dateToZulu", function (date) {
|
||||||
if (!date) return "";
|
if (!date) return "";
|
||||||
@ -422,6 +417,13 @@ module.exports = function (eleventyConfig) {
|
|||||||
return variable;
|
return variable;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
eleventyConfig.addPlugin(pluginRss, {
|
||||||
|
posthtmlRenderOptions: {
|
||||||
|
closingSingleTag: "slash",
|
||||||
|
singleTags: ["link"],
|
||||||
|
},
|
||||||
|
});
|
||||||
|
|
||||||
userEleventySetup(eleventyConfig);
|
userEleventySetup(eleventyConfig);
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
"author": "",
|
"author": "",
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@11ty/eleventy": "^2.0.0",
|
"@11ty/eleventy": "^2.0.1",
|
||||||
"@11ty/eleventy-plugin-rss": "^1.2.0",
|
"@11ty/eleventy-plugin-rss": "^1.2.0",
|
||||||
"cross-env": "^7.0.3",
|
"cross-env": "^7.0.3",
|
||||||
"html-minifier": "^4.0.0",
|
"html-minifier": "^4.0.0",
|
||||||
|
@ -7,8 +7,8 @@
|
|||||||
{%if meta.siteBaseUrl %}<?xml version="1.0" encoding="utf-8"?>
|
{%if meta.siteBaseUrl %}<?xml version="1.0" encoding="utf-8"?>
|
||||||
<feed xmlns="http://www.w3.org/2005/Atom" xml:base="{{ meta.siteBaseUrl }}">
|
<feed xmlns="http://www.w3.org/2005/Atom" xml:base="{{ meta.siteBaseUrl }}">
|
||||||
<title>{{ meta.siteName}}</title>
|
<title>{{ meta.siteName}}</title>
|
||||||
<link href="{{ meta.siteBaseUrl }}{{ permalink }}" rel="self"//>
|
<link href="{{ meta.siteBaseUrl }}{{ permalink }}" rel="self" ////>
|
||||||
<link href="{{ meta.siteBaseUrl}}" //>
|
<link href="{{ meta.siteBaseUrl }}" ////>
|
||||||
<updated>{{ collections.notes | getNewestCollectionItemDate | dateToRfc3339 }}</updated>
|
<updated>{{ collections.notes | getNewestCollectionItemDate | dateToRfc3339 }}</updated>
|
||||||
<id>{{ meta.siteBaseUrl }}</id>
|
<id>{{ meta.siteBaseUrl }}</id>
|
||||||
{%- for note in collections.note | reverse %}
|
{%- for note in collections.note | reverse %}
|
||||||
@ -23,7 +23,7 @@
|
|||||||
<content type="html">
|
<content type="html">
|
||||||
{{ note.templateContent | hideDataview | link | taggify | htmlToAbsoluteUrls(meta.siteBaseUrl) }}
|
{{ note.templateContent | hideDataview | link | taggify | htmlToAbsoluteUrls(meta.siteBaseUrl) }}
|
||||||
</content>
|
</content>
|
||||||
<link href="{{ meta.siteBaseUrl }}{{note.url | url }}" //>
|
<link href="{{ meta.siteBaseUrl }}{{note.url | url }}" ////>
|
||||||
</entry>
|
</entry>
|
||||||
{%- endfor %}
|
{%- endfor %}
|
||||||
</feed>
|
</feed>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user