From 74089b3057afd5e51a5bf99a5c35b5197c7fe08e Mon Sep 17 00:00:00 2001 From: Jacky Zhao Date: Mon, 24 Jul 2023 00:07:58 -0700 Subject: [PATCH] actually add processed tag to frontmatter --- quartz/plugins/transformers/ofm.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/quartz/plugins/transformers/ofm.ts b/quartz/plugins/transformers/ofm.ts index 36e79b01..9840ea8b 100644 --- a/quartz/plugins/transformers/ofm.ts +++ b/quartz/plugins/transformers/ofm.ts @@ -331,6 +331,10 @@ export const ObsidianFlavoredMarkdown: QuartzTransformerPlugin const slug = canonicalizeServer(file.data.slug!) const base = pathToRoot(slug) findAndReplace(tree, tagRegex, (value: string, tag: string) => { + if (file.data.frontmatter) { + file.data.frontmatter.tags.push(tag) + } + return { type: "link", url: base + `/tags/${slugAnchor(tag)}`,