Ghost Letters 幽霊文字

Improve Mastodon Preview

Improve Mastodon Preview

I noticed that some preview cards on Mastodon look nicer than the ones from my blog. For instance, the articles from Bert Hubert’s blog show a time stamp in the preview. Furthermore, the whole preview formatting is different and IMHO looks nicer.

compare mastodon preview cards side by side

So I added (or copy pasted) some of the meta data into my Hugo template.

Sidenote: Huge/Go should up their game and provide an ISO 8601 formatter for datetime out of the box. Shame on you. Even Python can handle this by now. How long does it take to copy that stuff over from Java? :P


Turns out, most of the formatting difference is due to the missing ogImage tag. So I should remember to add some little picture - like I did in the past, before I became to lazy. 😄