fix(blog): Fix homepage link in RSS feed#8089
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
cc @nodejs/nodejs-website we should add a description to our |
| language: 'en', | ||
| link: `${canonicalUrl}/feed/${file}`, | ||
| description: description, | ||
| link: `${canonicalUrl}/`, |
There was a problem hiding this comment.
| link: `${canonicalUrl}/`, | |
| link: canonicalUrl, |
avivkeller
left a comment
There was a problem hiding this comment.
Wow! This was simple, informative, and an overall great PR. Keep up the good work, @Krinkle!
|
(Relevant spec details: https://www.rssboard.org/rss-specification#requiredChannelElements) |
good idea |
|
Lighthouse Results
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files☔ View full report in Codecov by Sentry. |
|
@Krinkle can you resolve the failed test? |
|
Sorry, it took me a while to find what the problem was because the CI job output just says "Command failed with exit code 1" with no discernable information about what or why failed. I closed and re-opened the PR as a way to retry the jobs, on the assumption it was some kind of race condition. Anyway, I see that the code coverage bot is doubling as test result reporter. Fix incoming. |
When following the Node.js Blog at https://nodejs.org/en/blog in a feed reader like NetNewsWire, the homepage link gets broken. Instead of navigating the browser to the website, one gets a blank page and an unexpected RSS feed download in the background. The `<link>` tag in RSS 2.0 is for the HTML website. Note that the "self" link from the RSS file back to itself is separate form this and already auto-generated by the Feed class. [1] While at it, fix the broken `<description>undefined</defined>` element. This is often left empty and fine not to pass in `/apps/site/site.json`. However, the upstream Feed class has a bug where it takes the undefined and outputs the string "undefined" as the blog's description instead of a sensible default like empty string. [1]: https://github.com/jpmonette/feed Signed-off-by: Timo Tijhof <krinkle@fastmail.com>
Description
When following the Node.js Blog at https://nodejs.org/en/blog in a feed reader like NetNewsWire, or when sharing a blog roll via OPML (example), the homepage link gets broken.
Instead of navigating the browser to the website, one gets a blank page and an unexpected RSS feed download in the background.
The
<link>tag in RSS 2.0 is for the HTML website. The "self" link for the RSS file itself is already generated by jpmonette/feed package.While at it, fix the broken
<description>undefined</defined>element. This is often left empty and fine not to pass in/apps/site/site.json. However, the upstream Feed class has a bug where it takes the undefined and outputs the string "undefined" as the blog's description instead of a sensible default like empty string.Validation
Related Issues
Check List
pnpm formatto ensure the code follows the style guide.pnpm testto check if all tests are passing.pnpm buildto check if the website builds without errors.