Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Microformats markup #160

Merged
merged 2 commits into from
Dec 28, 2017
Merged

Add Microformats markup #160

merged 2 commits into from
Dec 28, 2017

Conversation

barryf
Copy link
Contributor

@barryf barryf commented Sep 22, 2017

This PR adds Microformats markup to Minima's templates to make post content machine-readable and discoverable.

Microformats makes HTML content as easy to consume as JSON APIs without needing a separate feed. Parser libraries are available for Ruby, Python, PHP, Node and Go and more.

W3C recommended protocols, including Webmention and Micropub depend on Microformats and so it would be a great help for the default Jekyll theme's templates to support them.

I've tried to make the changes as lightweight as possible, but I'm open to any suggestions or improvements.

@tantek
Copy link

tantek commented Sep 22, 2017

I have reviewed the diffs for the source and the Example Jekyll post with Microformats markup output and they look good to me.

@pathawks
Copy link
Member

@barryf Thanks for the PR!

Minima already relies on jekyll-seo-tag for providing microdata, which is consumed by Google, Facebook, Twitter, etc. It seems that with HTML5, microdata is being favored over the old Microformats.

Including Microformats in addition to Microdata would result in a lot of duplicated information. What are the concrete benefits of including both?

@DirtyF
Copy link
Member

DirtyF commented Sep 22, 2017

@barryf microformats website says it supersedes microdata but I see that a spec was recently published on https://www.w3.org/TR/microdata/

So what are the concrete applications of adding microformats if microdata is still a thing for the w3c? 🤔

/cc @aarongustafson (developer the webmention plugin for Jekyll) who might enlighten us on that very matter 💡

@barryf
Copy link
Contributor Author

barryf commented Sep 23, 2017

Thanks for reviewing, @pathawks and @DirtyF. I can’t comment on Microdata and its positioning in W3C (perhaps @tantek can?) but from my experience the strength of Microformats is the many implementations being used that are built on them.

Brid.gy pulls comments, likes, and reshares on social networks back to your website by marking them up in Microformats (e.g. 1 and 2 from Twitter) for your site to parse. @aarongustafson’s Webmention plugin uses the webmention.io service to parse these responses to your posts in Microformats and makes them available to your Jekyll site to include as comments.

Microformats are now supported by default in Mastodon - the largest decentralised microblogging network - and Micro.blog - a new social network for independent microblogs. All sites using Known, a social learning platform, have Microformats and there are hundreds of sites built by members of the IndieWeb community.

@aarongustafson
Copy link

There is very little downside to supporting both microformats and microdata and a lot of upside to supporting both. Microdata can be useful in sharing contexts (alongside OpenGraph data as well) and in search. Microformats are also considered in search contexts as well as in the tools @barryf mentioned and in services like Mercury (née Readability). Additionally, they provide a nice clean set of class names for styling (and you’re probably are already using a set of class-es for the info the various microformats are identifying, so i’t no like we’re adding a lot of cruft here).

Copy link
Member

@DirtyF DirtyF left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's go with Microformats then 😄

@aterenin
Copy link

I'd encourage folks to be careful with precisely where the markup is added, to ensure it is accurate even for sites that are not blogs.

For example, the microformats page says that:

rel="me" is used on hyperlinks from one page about a person to other pages about that same person.

Should we use rel="me" in the case that the site is about a project and not a person?

Similarly, this page says that:

rel="author" is for relating an article or post to a page or site representing its author, typically to give them credit for their work (or portions of it, like books, articles, blog posts etc).

Does it make sense to add rel="author" to the title link, if the page used is for a GitHub project? In that case shouldn't rel="author" be used if the page links to the authors' homepage, not to itself?

I'm not familiar enough with microformats to answer these questions, I would encourage folks to consider them.

@DirtyF DirtyF merged commit 68b85c1 into jekyll:master Dec 28, 2017
@jekyll jekyll locked and limited conversation to collaborators Apr 30, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.