Browse Source

gts comments tweak

master
Jon Kelbie 5 months ago
parent
commit
903d0a7dbc
  1. 5
      layouts/partials/mastodon/mastodon.html

5
layouts/partials/mastodon/mastodon.html

@ -57,10 +57,7 @@
document.getElementById("load-comment").addEventListener("click", function() {
document.getElementById("load-comment").innerHTML = "Loading";
require('dotenv').config();
const key = process.env.API_KEY;
const headers = { 'Authorization': '${key}' }; // auth header with bearer token
fetch('https://{{ .Site.Params.comment.fediverse.host }}/api/v1/statuses/{{ .Page.Params.comments.id }}/context', { headers })
fetch('http://localhost:7777/api/v1/statuses/{{ .Page.Params.comments.id }}/context')
.then(function(response) {
return response.json();
})

Loading…
Cancel
Save