Show empty pages

This commit is contained in:
Christoph Hagen
2022-08-29 19:20:13 +02:00
parent 3f1971c5bd
commit 5ec283e4d4
4 changed files with 28 additions and 2 deletions

View File

@ -49,10 +49,13 @@ struct PageGenerator {
}
let url = files.urlInOutputFolder(path)
if pageContent == nil {
files.isEmpty(page: path)
}
guard factory.page.generate(content, to: url) else {
return
}
log.add(info: "Generated \(pageContent == nil ? "empty page " : "")\(path)", source: page.path)
log.add(info: "Page generated", source: path)
}
private func makeContent(page: Element, language: String, path: String) -> (content: String, includesCode: Bool)? {