grant.codes

Jump to menu
  • About
  • Contact
  • Projects
  • Updates
  • More...Likes
  • Photos
  • Galleries
  • Replies
πŸ‘ˆπŸ•ΈπŸ’πŸ‘‰

Liked https://sebastiandedeyne.com/adding-webmentions-to-my-blog/

Adding webmentions to my blog

I first noticed webmentions in the wild on Hidde de Vries’ blog about two years ago. Last week it finally happened, I added webmention support to my blog too! Well, partial support at least. I’m now receiving and displaying webmentions. Sending them out is a project for another day.

Whatmentions?

Webmentions.

Webmention is a web standard for mentions and conversations across the web, a powerful building block that is used for a growing federated network of comments, likes, reposts, and other rich interactions across the decentralized social web.

indieweb.org

Webmentions are a protocol for websites to communicate across each other. What makes the webmention standard interesting is that it’s not tied to a single service  it’s a protocol. Webmentions can be aggregated from a range of different services from Twitter, to other blogs or even direct comments.

I highly recommend Chris Aldrich’s article on A List Apart if you want to dive deeper in the theory about the standards recommendation.

Receiving webmentions

I’m mostly interested in receiving webmentions from Twitter since that’s my main source of traffic.

Twitter doesn’t send any webmentions themselves. Fortunately there’s a service that solves this problem: Bridgy. Whenever a link to my blog is posted on Twitter, Bridgy polls for replies, retweets, and likes to send them as webmentions.

That’s just half of the story: the mentions need to be received too. When a webmention is sent, the sender will scan for a specific link tag on the mentioned page.

<link rel="webmention" href="...">

If it finds one, it will post the mention to the configured URL.

I set up my to receive webmentions on another third party service: Webmention.io.

<link rel="webmention" href="https://webmention.io/sebastiandedeyne.com/webmention" />

Webmention.io stores webmentions on their servers, so I can retrieve them to display on my blog. It also acts as a spam filter. Fake mentions from bots will be filtered out so they won’t appear under my posts.

To summarize the flow:

  • Someone tweets a link to one of my posts, or interacts with a tweet that contains a links to one of my posts
  • Bridgy polls Twitter, and discovers the interaction
  • Bridgy posts a webmention to my website
  • The webmention is routed to Webmention.io and stored

Displaying webmentions on post pages

Webmentions stored on Webmention.io can be retrieved with a simple API call. For example, to receive mentions for this post:

https://webmention.io/api/mentions.jf2?target=https://sebastiandedeyne.com/adding-webmentions-to-my-blog

I’m using the fetch API to grab the webmentions JSON, have a rudimentary script to render them beneath every post.

That’s all there is to it! Most of the mentions I’m receiving are from Twitter, but anyone can add comments with a service like comment parade too. Try it out by mentioning this post!

Posted Permalink
Liked 7 years ago by
Grant Richmond

Liked https://www.reddit.com/r/Eyebleach/comments/cd8jkh/soft_pets_for_this_weird_dog/?utm_source=ifttt

Soft pets for this weird dog

Soft pets for this weird dog from Eyebleach
Posted 7 years ago by
mayaxs
Liked 7 years ago by
Grant Richmond

Liked https://www.reddit.com/r/Eyebleach/comments/ccqyip/corgi_pupper_discovers_the_magic_of_door_stoppers/?utm_source=ifttt

Corgi pupper discovers the magic of door stoppers

Corgi pupper discovers the magic of door stoppers from Eyebleach
Posted 7 years ago by
to_the_tenth_power
Liked 7 years ago by
Grant Richmond

Liked https://www.reddit.com/r/PeopleFuckingDying/comments/cc9p6h/hero_boy_saves_kitty_from_certain_death/?utm_source=ifttt

HErO bOy sAvEs kItty frOm cErtAIn dEAth!

HErO bOy sAvEs kItty frOm cErtAIn dEAth! from PeopleFuckingDying
Posted 7 years ago by
varungupta3009
Liked 7 years ago by
Grant Richmond

Liked https://usefulinterweb.com/post/186213206819

Useful Interweb

Jul 11, 2019
Posted Permalink
Liked 7 years ago by
Grant Richmond

Liked https://www.reddit.com/r/AbsoluteUnits/comments/cbig8n/absoloute_unit_has_too_many_snags/?utm_source=ifttt

Absoloute Unit has too many snags.

Absoloute Unit has too many snags. from AbsoluteUnits
Posted 7 years ago by
Dirt1488
Liked 7 years ago by
Grant Richmond

Liked https://twitter.com/MatthewRayfield/status/1148936557774217216

Matthew Rayfield on Twitter

i made a new WEB TOY thing !

🎺 POPUP TROMBONE 🎺

it's a trombone you play by resizing a POPUP window
(but it doesn't really sound like a trombone, sorry)

🎺 play it here: https://t.co/7DxY0AGdnA 🎺

( and unmute to hear my BEAUTIFUL rendition of "mary had a little lamb" ) πŸ‘ pic.twitter.com/u10G2J7G7J

— Matthew Rayfield (@MatthewRayfield) July 10, 2019
Posted 7 years ago
Liked 7 years ago by
Grant Richmond
● Also on:

Liked https://www.jvt.me/posts/2019/07/09/post-visualisation/

Visualising My Posting Habits

For a while now I've been looking at getting some insight into how often I post content to this site for two reasons - purely for interest, and to watch how it changes over time.

With this post, you can now go over to /post-frequency/ to see the latest graphical breakdown of my posting content - I'd recommend it to know what's actually being talked about!

To generate these charts, I've created a Hugo template that generates a set of counts for each of the content types that I regularly publish (i.e. ignoring static content like events or talks), which is then rendered by Chart.JS as a line chart.

Some interesting pieces of data I've gleaned from the stats as they currently sit:

  • I post more content either early evening or just before bed
  • I seemingly post a lot on the 7th of the month, but not much on the 8th, 21st or 27th
  • Thursdays and Sundays are my most popular days
  • March is my most productive month of content - most likely because I usually take a week's holiday over my birthday, so I end up writing a lot while I'm off

I'm looking forward to keep an eye on the way that my content publishing changes over time, i.e. with the use of Micropub for posting from anywhere.

Posted 7 years ago by
Jamie Tanna
● Categories: #www.jvt.me ● Also on: news.indieweb.org indieweb.xyz
Liked 7 years ago by
Grant Richmond

Liked https://www.reddit.com/r/youtubehaiku/comments/cagv2n/haiku_insanely_close_call_with_a_wild_shrek/?utm_source=ifttt

Liked 7 years ago

Liked https://css-tricks.com/indieweb-and-webmentions/

Liked 7 years ago
NewerOlder
EmailInstagramGithub

Grant Richmond
grant.codesmail@grant.codes