-
-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(feed_tag): support parsing config.feed #4029
Conversation
lib/plugins/helper/feed_tag.js
Outdated
if (type === 'atom' || path.includes('atom')) typeAttr = 'type="application/atom+xml"'; | ||
else if (type.includes('rss') || path.includes('rss')) typeAttr = 'type="application/rss+xml"'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there is an edge case, feed_tag('feed.xml')
and type
is not specified; typeAttr
will be empty as "feed.xml" can refer to atom or rss.
It's fine to leave it empty since currently this helper doesn't add type="application/atom+xml"
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
What does it do?
hexojs/hexo-theme-unit-test#25 (comment)
also add
type="application/atom+xml"
if the type can be determined.How to test
Pull request tasks