mirror of
https://github.com/jackyzha0/quartz.git
synced 2025-12-24 05:14:06 -06:00
filter files on rebuild
This commit is contained in:
parent
52a5196f38
commit
2f41c06336
@ -251,9 +251,11 @@ async function rebuild(changes: ChangeEvent[], clientRefresh: () => void, buildD
|
|||||||
// update allFiles and then allSlugs with the consistent view of content map
|
// update allFiles and then allSlugs with the consistent view of content map
|
||||||
ctx.allFiles = Array.from(contentMap.keys())
|
ctx.allFiles = Array.from(contentMap.keys())
|
||||||
ctx.allSlugs = ctx.allFiles.map((fp) => slugifyFilePath(fp as FilePath))
|
ctx.allSlugs = ctx.allFiles.map((fp) => slugifyFilePath(fp as FilePath))
|
||||||
const processedFiles = Array.from(contentMap.values())
|
let processedFiles = filterContent(ctx,
|
||||||
|
Array.from(contentMap.values())
|
||||||
.filter((file) => file.type === "markdown")
|
.filter((file) => file.type === "markdown")
|
||||||
.map((file) => file.content)
|
.map((file) => file.content)
|
||||||
|
)
|
||||||
|
|
||||||
let emittedFiles = 0
|
let emittedFiles = 0
|
||||||
for (const emitter of cfg.plugins.emitters) {
|
for (const emitter of cfg.plugins.emitters) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user