After recently moving my site from WordPress to Docusaurus, I decided I wanted a comments feature. Not because I got many comments before, nor have I written here in years (something I hope to write about soon), but for the challenge.
Docusaurus is a static site generator (SSG), so self-hosted comments seem impossible. And I find tools like Discus distasteful since they use a single login one can be tracked across multiple domains.
Today I found giscus, and had it set up in less than an hour. It uses GitHub's API to treat the discussions section of a repository as a data source for comments.
While I have my own issues with GitHub post-acquisition, it's a far better solution than tying in Discus, Google, or Facebook to my site. And since I use Docusaurus for professional documentation sites, it's a nice lower barrier to entry for non-technical folks to engage with content, and only one extra click to turn a discussion item into an issue. So my blog made for a perfect sandbox to test it out.
One of the most prominent search result for a guide is behind Medium's paywall, so I figured I'd write up the process myself.