If you’re hosting a blog on GitHub Pages, sometimes you wish you could include a “last modified” snippet on posts which you’ve revisited, updated, or modified after the initial publication. Sure, there’s a
jekyll-last-modified-at plugin, but it’s not part of the GitHub Pages plugin whitelist, so you would have to locally build your site into HTML on each commit for GitHub Pages to statically serve pages with a baked-in “last modified” time. You could also include e.g. a
last_modified variable in your YAML Front Matter which you manually update, but if you’re trying to add it to a site which has a lot of old posts, this might be somewhat error-prone and tedious.
page.path will be expanded correctly, or alternately you could pass it in as a JS variable if you want to get fancy.