Skip to content

Instantly share code, notes, and snippets.

View am1t's full-sized avatar

Amit Gawande am1t

View GitHub Profile
@am1t
am1t / feed.xml
Last active August 14, 2018 04:50
Feedbin debug report for a Blot blog feed
<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0">
<channel>
<title>Excursions</title>
<link>https:&#x2F;&#x2F;blog.amitgawande.com</link>
<atom:link href="https:&#x2F;&#x2F;blog.amitgawande.com/feed.rss" rel="self" type="application/rss+xml"/>
<description><![CDATA[ Blog by Amit Gawande ]]></description>
<item>
<title><![CDATA[ ]]></title>
<link>https://blog.amitgawande.com&#x2F;1534216293963</link>
@am1t
am1t / webmention.js
Last active May 19, 2019 18:09
Javascript snippet to fetch Webmentions
var post_url = window.location.href;
$(document).ready(function(){
$("ul#mentions-list").empty();
$.getJSON("https://webmention.io/api/mentions?per-page=50&page=0&jsonp=?", {
target: post_url
}, function(data){
var social_media_likes = "";
var social_media_repost = "";
var social_media_post = "";
@am1t
am1t / flashback.js
Created February 7, 2019 11:31
Javascript snippet to fetch posts made On This Day for Blot blog
let json_feed_url = "YOUR_JSON_FEED_URL_HERE";
let tz = "YOUR_LOCAL_TIMEZONE";
let container = document.getElementById('on-this-day');
function renderPost(post) {
var postEl = document.createElement('article');
postEl.className = 'h-entry entry';
container.appendChild(postEl);
if (post.title != null) {
@am1t
am1t / on-this-day.html
Last active February 7, 2019 11:36
HTML page for "On This Day" feature for a Blot blog
<!DOCTYPE html>
<html>
{{> head}}
<body>
{{> header}}
<div class="container">
<div class="main">
<h1 class="page-title p-name">On This Day</h1>
<div id="on-this-day">
Loading...