Follow

Let's try this one more time...

Can I use Mastodon for commenting on my blog?

leo.fm/2022/02/comments/

Purify.min.js is now installed. I think.

@leo Ah! Leo Laporte is on Mastodon?! I've been such fan of yours for so long!

So cool!

@nathand Thanks! Nice to meet you. I've been here forever. We ran an Identica instance called the TWiT Army some years ago. After Mastodon started I created an account at mastodon.social, and a couple of years ago started a dedicated TWiT instance at twit.social. I really do love the Fediverse and all things Open Web.

@leo I'm really glad to hear it.

I saw you were having problems with the page, so I took a look.

Looks like DOMPurity is hitting a 404 on your site.

I'm not sure how you're set up with Hugo and hosting/cache, etc, but it could be that the file isn't getting pushed, or it's not being picked up by the cache.

I imagine you've seen all of this by now, but I hope it helps.

@nathand I am such a pathetic hack. I put the js code everywhere I could think of. Finally worked when I put it in /static/assets/js/ - so it works! Yay!

@leo Sounds like Hugo 😆. I spent a lot of time trying to wrap my head around the template system. Sometimes I forget that the top-level static directory is merged with the rest of the theme and theme-specific static directories.

Glad you got it fixed.

@nathand Yeah! Hugo + Mastodon is open source heaven!

@leo Neat. It would be nice if it threaded it right on your blog page though rather than dumping out to the Mastodon UI. Not that I dislike the Mastodon UI, it's just a bit of a janky experience.

@mike_mattatall Yeah I agree it's jarring to be pushed out into Mastodon. I'm not sure how else to do it, though. Maybe in an iFrame?

Mastodon is doing all the heavy lifting - and the comments are full Mastodon posts, which is part of the benefit I think. It makes it a community discussion.

Ugly as it is I'll probably keep it.

@leo works great! So glad you're promoting the fediverse:)

@leo testing out the commenting function... Thanks for always being on the bleeding edge...

@leo Here is the reason:

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at twit.social/api/v1/statuses/10… (Reason: CORS request did not succeed).

@roland Interesting. I wonder if it's something running on your system. I don't get any errors with Firefox and Ublock Origin.

@leo Hmm, odd. I opened about:config and searched for "origin" and found no modified configuration entries.
Saw this and had to test it for myself...

This is an awesome idea! I love the idea of linking Hugo to the Fediverse for comments. ;-)

@leo Oh! This is really cool. I was thinking about adding commento to my Hugo blog but then just happened on your post! Since I’m diving into Mastodon at the moment I’ll see if I can get this working!

Greetings from Hubzilla. What happens if I put an image in this comment?

Sign in to participate in the conversation
TWiT.social

A Mastodon instance dedicated to TWiT listeners. Think of a Twitter just for geeks, sharing content with other Mastodon servers all over the world. If you're a TWiT fan, consider this your home! Our TWiT Forums live at TWiT Community. Post conversation starters there. TWiT.social is for quick thoughts, fun pictures, and other ephemera. Keep it clean, keep it friendly. Looking forward to your Toots!