This commit is contained in:
2024-08-06 08:05:43 -07:00
commit 129b64a0fb
232 changed files with 39208 additions and 0 deletions

View File

@ -0,0 +1,9 @@
import { QuartzFilterPlugin } from "../types"
export const RemoveDrafts: QuartzFilterPlugin<{}> = () => ({
name: "RemoveDrafts",
shouldPublish(_ctx, [_tree, vfile]) {
const draftFlag: boolean = vfile.data?.frontmatter?.draft ?? false
return !draftFlag
},
})

View File

@ -0,0 +1,8 @@
import { QuartzFilterPlugin } from "../types"
export const ExplicitPublish: QuartzFilterPlugin = () => ({
name: "ExplicitPublish",
shouldPublish(_ctx, [_tree, vfile]) {
return vfile.data?.frontmatter?.publish ?? false
},
})

View File

@ -0,0 +1,2 @@
export { RemoveDrafts } from "./draft"
export { ExplicitPublish } from "./explicit"