calintat / minimal

Personal blog theme powered by Hugo
https://themes.gohugo.io/minimal/
MIT License
404 stars 221 forks source link

RSS feed integration #30

Closed vncntvandriessche closed 6 years ago

vncntvandriessche commented 6 years ago

I'm looking for support for RSS feeds (I like using RSS feeds myself)

Willing to look into it myself if I could get some directions of course!

jamestharpe commented 6 years ago

Hugo does this out of the box and the minimal theme supports it already by embedding {{ .RSSLink }} in the header.html file. I didn't do anything special to my website to get RSS working, you can view it here: https://www.jamestharpe.com/index.xml

Are you looking for more than that? If so, what specifically?

vncntvandriessche commented 6 years ago

@jamestharpe Thanks for clearing that up, I now see that the site actually generates the link.

It seems the generated site isn't actually displaying the link though? Am I doing something wrong?

jamestharpe commented 6 years ago

Make sure don't have disableRSS = true in your config.toml. You might also try setting it explicitly to false. Also make sure your theme is up-to-date.

vncntvandriessche commented 6 years ago

I've tried all of your suggestions, but now that I think about it it seems logical to me that there's no visible link to the RSS feed, as there's no element in the body-section of the generated HTML to show the link?

jamestharpe commented 6 years ago

Ooohhh... you want a VISIBLE link 😃 ! IME, RSS readers understand the <link ... code and a visible link isn't usually necessary. That said, you can add this by adding a [[menu.icon]] entry in your config.toml. Here's an example:

[[menu.icon]]
    url = "/index.xml"
    name = "rss"
    weight = 6
jamestharpe commented 6 years ago

A note on how this works, in case you (or anyone else) want to add more icons to the menu.icon - the name of the menu-icon entry just has to match an fa- class from Font-Awesome. So, for example, if you wanted people to contact you in the shower, you could specify name = bath in your config.toml 😁

vncntvandriessche commented 6 years ago

@jamestharpe That is what I was looking for and BEYOND 😆 .

Thank you so much!