1
Fork 0

Documentation!

This commit is contained in:
Bauke 2023-08-03 14:33:13 +02:00
parent fbbf424cb5
commit d03dc23d4d
Signed by: Bauke
GPG Key ID: C1C0F29952BCF558
1 changed files with 2 additions and 0 deletions

View File

@ -1,6 +1,7 @@
import { Command } from "./dependencies.ts"; import { Command } from "./dependencies.ts";
import { runCommand, tomlFrontmatter } from "./utilities.ts"; import { runCommand, tomlFrontmatter } from "./utilities.ts";
/** The TOML frontmatter data for each video. */
type Frontmatter = { type Frontmatter = {
page_title: string; page_title: string;
id: string; id: string;
@ -65,6 +66,7 @@ async function main(): Promise<void> {
}); });
} }
/** Format the description using the video's frontmatter data. */
function formatDescription(frontmatter: Frontmatter): string { function formatDescription(frontmatter: Frontmatter): string {
let description = "See all details on my website\n"; let description = "See all details on my website\n";
description += `https://bauke.xyz/v/${frontmatter.id}/\n`; description += `https://bauke.xyz/v/${frontmatter.id}/\n`;