import ejs from "ejs"; import * as metadata from "../metadata"; import layout from "../layout"; import * as util from "../util"; export default async function missing() { const page = await metadata.get("site/404.html.ejs"); page.text = ejs.render(page.text, { metadata: page.metadata }, { filename: "site/404.html.ejs" }); page.text = await layout(page.text, page.metadata, page.metadata.layout!); util.write("404.html", page.text); }