I hereby claim:
- I am gr36 on github.
- I am gr36 (https://keybase.io/gr36) on keybase.
- I have a public key ASASCGNA3-ldd5rZ1wK4klg7menMZrR4oPp43EUS7G05vQo
To claim this, I am signing this object:
| import SwiftUI | |
| struct PostContent: View { | |
| @Environment(\.openURL) private var openURL | |
| @EnvironmentObject private var appearanceManager: AppearanceManager | |
| @EnvironmentObject private var videoManager: VideoPlayerManager | |
| let content: String | |
| @State private var showingProfile = false | |
| @State private var selectedUsername: String? | |
| @State private var showingShareSheet = false |
| const fs = require('fs'); | |
| const axios = require('axios'); | |
| // Function to fetch all posts of a user | |
| async function fetchUserPosts(instanceURL, accessToken, username) { | |
| try { | |
| const response = await axios.get(`${instanceURL}/api/v1/accounts/${username}/statuses`, { | |
| headers: { | |
| Authorization: `Bearer ${accessToken}`, | |
| }, |
| eleventyConfig.addFilter("countWebmentions", function(webmentionsFilePath, url) { | |
| // Load and parse the webmentions JSON file | |
| const data = JSON.parse(fs.readFileSync(webmentionsFilePath, 'utf8')); | |
| // Filter webmentions based on the provided URL | |
| const filteredWebmentions = data.children.filter(entry => { | |
| return entry['like-of'] === url || entry['in-reply-to'] === url || entry['repost-of'] === url; | |
| }); | |
| // Initialize counts for each type |
| // Add a date filter | |
| eleventyConfig.addFilter("dateFormat", function(date) { | |
| const year = date.getFullYear(); | |
| const month = ('0' + (date.getMonth() + 1)).slice(-2); // Adds leading 0 for single digit months | |
| const day = ('0' + date.getDate()).slice(-2); // Adds leading 0 for single digit days | |
| return `${year}/${month}/${day}`; | |
| }); |
| routes: | |
| /rss/: | |
| template: /rss/ | |
| content_type: text/xml | |
| collections: | |
| /: | |
| permalink: /{slug}/ | |
| template: index | |
| filter: tag:-[links,newsletter,notes,micro] |
I hereby claim:
To claim this, I am signing this object: