A simple, dependency-free script to add Mastodon-powered comments to your site. For details see Adding comments to your blog, powered by mastodon
Turn this HTML
<div id="comments"></div>
<script>
addEventListener('DOMContentLoaded', (event) => window.loadComments('{mastodon}',document.getElementById('comments')));
</script>
into this:
- If you ever need to migrate your mastodon account, you'll typically loose all your old posts, including your old blog comments.
- Unless you are a moderator on your mastodon instance, you have no moderation ability on your comments. That could be a big deal.
- If your blog visitors have accounts on instances that have de-federated from your instance (or the other way around), they will not be able to comment.
- In short, unless you are using your own Mastodon instance, you'll need to put a lot of trust into your instance's admins.
- As much as I'd like to think that my blog posts are so engaging people will sign up to Mastodon in droves just to be able to comment on my posts, that's obviously not happening, so essentially you'll only get comments from existing Fediverse users.
- Mastodon has a rate limit on that context API endpoint, so if you get loads of visitors to your blog, you may need to cache responses somewhere.