Comments via Mastodon


I recently saw two posts on Mastodon about using Mastodon as a blog commenting system / guestbook:

Which had me curious. I like the idea of being able to add conversation to a static blog like this with relatively minimal overhead. The first uses David Darne’s webcomponent. The second uses a combination of webmentions.io and bridgy. There’s a more in-depth write up on that option here: Receiving blog replies from anywhere on the Web.

While I like the idea of webmentions, it didn’t feel as much of a quick plug-and-play option for my current setup, so I looked around some more. I found this post: Use Mastodon as a Comment System (and left a comment on it), which led me to another web component and an in-depth blog post about that: Mastodon as comment system for your static blog by Daniel Pecos Martínez.

It’s not quite a comment system as you need to bounce out to Mastodon to leave a comment but it handles replies and attachments and anything else quite nicely. As that blog post notes though, it’s more open than something like Disqus, which has it’s appeal.

I ended up not using the web component as is, I (perhaps foolishly) read the blog post about it and then wrote it in React and stuck it in this Next.js site. I haven’t gotten ambitious enough to package it up yet, but the code is here in a codesandbox if you want it!

Tagged: meta

"loading posts from Mastodon..."