Open retifrav opened 5 years ago
ololo
Some markdown stuff:
code
a quote
// comment inside a comment!
console.log("and a code block");
Cool, huh.
Even images!
Thank you for the blog about adding comments using GitHub within Hugo. Does it mean we need to come to this page every time we want to comment? Even so, this solution is very neat! I love it!
Yes, adding comments is possible only here, in GitHub issues. The blog just allows to view them right under the articles.
Cool. Thanks!
What about theming? I want dark comments :P
Well, just modify the CSS, that's easy. What's not so easy is finding the right/nice colors palette.
This is awesome.
I'll use it on my site.
I am trying to set up this commenting system on my blog, but ran into trouble on this step
"And then edit the page layout (/themes/YOUR-THEME/layouts/_default/single.html):"
I modified the correct file, but the div with "comments" ID never gets added to my page. Verified by checking the HTML source. Think hugo might be caching the post or something. So I tried by clearing the public directory and then starting the server, but no luck :(
Another thing I couldn't figure out was where to add the CSS for styling the comments.
Will be great if you can help out with these! =)
It could be that you've edited single.html
template of a wrong theme, so your Hugo actually uses a different theme. Alternatively, you can just edit the single.html
template in your "base" layouts folder (/layouts/blog/single.html
) - that should have higher priority in templates lookup, if I recall correctly.
As for CSS, I've just put it into its own file at /static/css/comments.css
and included that file in my baseof.html
.
Thanks. Turns out I was editing index.html rather than single.html. Working fine now 👍
Curious if this still works (thanks for the post, btw!)
Great article thanks
GitHub comments for a Hugo-based blog comments.