var url = "https://github.com/tomthomas/tomthomas.github.io/issues/" + {{ $.Params.ghcommentid }} var api_url = "https://api.github.com/repos/tomthomas/tomthomas.github.io/issues/" + {{ $.Params.ghcommentid }} + "/comments" $(document).ready(function () { $.ajax(api_url, { headers: {Accept: "application/vnd.github.v3.html+json"}, dataType: "json", success: function(comments) { $("#gh-comments-list").append("Visit the Github Issue to comment on this post"); $.each(comments, function(i, comment) { var date = new Date(comment.created_at); var t = "