Fix RSS feed not transforming input path
This commit is contained in:
parent
f9fdb7ae23
commit
26aa6ba2e1
18
src/feed.njk
18
src/feed.njk
|
@ -12,20 +12,20 @@ eleventyComputed:
|
||||||
<subtitle>{{ sitemeta.siteDescription }}</subtitle>
|
<subtitle>{{ sitemeta.siteDescription }}</subtitle>
|
||||||
<link href="{{ sitemeta.feedUrl }}" rel="self"/>
|
<link href="{{ sitemeta.feedUrl }}" rel="self"/>
|
||||||
<link href="{{ sitemeta.siteUrl }}"/>
|
<link href="{{ sitemeta.siteUrl }}"/>
|
||||||
<updated>{{ collections.feedItems | getNewestCollectionItemDate | dateToRfc3339 }}</updated>
|
<updated>{{ collections["feed items"] | getNewestCollectionItemDate | dateToRfc3339 }}</updated>
|
||||||
<id>{{ feedMeta.baseUrl }}</id>
|
<id>{{ feedMeta.baseUrl }}</id>
|
||||||
<author>
|
<author>
|
||||||
<name>{{ sitemeta.siteAuthor.name }}</name>
|
<name>{{ sitemeta.siteAuthor.name }}</name>
|
||||||
<email>{{ sitemeta.siteAuthor.email }}</email>
|
<email>{{ sitemeta.siteAuthor.email }}</email>
|
||||||
</author>
|
</author>
|
||||||
{%- for item in collections["feed items"] | reverse | itemLimit(15) %}
|
{%- for item in collections["feed items"] | reverse | itemLimit(15) %}
|
||||||
{% set absolutePostUrl %}{{ item.url | absoluteUrl(feedMeta.baseUrl) }}{% endset %}
|
{% set absolutePostUrl %}{{ item.url | absoluteUrl(feedMeta.baseUrl) }}{% endset %}
|
||||||
<entry>
|
<entry>
|
||||||
<title>{{ item.data.title | safe }}</title>
|
<title>{{ item.data.title | safe }}</title>
|
||||||
<link href="{{ feedMeta.baseUrl if absolutePostUrl.includes("false") else absolutePostUrl }}"/>
|
<link href="{{ feedMeta.baseUrl if absolutePostUrl.includes("false") else absolutePostUrl }}"/>
|
||||||
<updated>{{ item.date | dateToRfc3339 }}</updated>
|
<updated>{{ item.date | dateToRfc3339 }}</updated>
|
||||||
<id>{{ feedMeta.baseUrl if absolutePostUrl.includes("false") else absolutePostUrl }}</id>
|
<id>{{ feedMeta.baseUrl if absolutePostUrl.includes("false") else absolutePostUrl }}</id>
|
||||||
<content type="html">{{ item.templateContent | htmlToAbsoluteUrls(absolutePostUrl) }}</content>
|
<content type="html">{{ item.content | renderTransforms(item.data.page, feedMeta.baseUrl) }}</content>
|
||||||
</entry>
|
</entry>
|
||||||
{%- endfor %}
|
{%- endfor %}
|
||||||
</feed>
|
</feed>
|
Loading…
Reference in New Issue