Closed palant closed 4 years ago
This is correct, but I'm not sure if it's worth it, considering the build time that may increase.
I investigated this issue a few weeks ago and it seems that Hugo will only apply the "make links absolute" logic to its own RSS feeds and there is no way to make it do the same for custom output formats.
This is weird, maybe we should consider it as an upstream issue and submit an issue in Hugo?
There we go: https://github.com/gohugoio/hugo/issues/7272
This is correct, but I'm not sure if it's worth it, considering the build time that may increase.
That argument should be moot given that build time appears to have dropped by ~25% due to recent changes. :wink:
Wow, then we can fix this issue now! Could you create a PR for this?
Never mind. I measured this properly for my site now - master
vs. v.4.3.1
(the latter required converting the config to TOML and adding utils/icon.html
partial). The build times didn't change noticeably, so I guess what I saw was due to changes in my site rather than MemE. In fact, even building a search index on the lunr-search
branch only increases the build times by ~2%.
On the other hand, removing these two regular expressions didn't change build times either - their impact is too small for me to measure (two RSS files, limit is 10 for both).
Yes, I just tested it with my site (one RSS file, 132 posts, no limits), and the impact is still very small.
So it's time to solve this issue now!
Pull request is https://github.com/reuixiy/hugo-theme-meme/pull/170.
W3C feed validator objects to the RSS feeds containing relative links: https://validator.w3.org/feed/docs/warning/ContainsRelRef.html. In fact, not all RSS feed readers will be able to correctly resolve those, which is why feed should always use absolute links. I investigated this issue a few weeks ago and it seems that Hugo will only apply the "make links absolute" logic to its own RSS feeds and there is no way to make it do the same for custom output formats.
Here is what my current work-around looks like: