Skip to content

Commit

Permalink
added custom data property for template instantiation (#716)
Browse files Browse the repository at this point in the history
  • Loading branch information
gorootde committed Feb 23, 2024
1 parent 702474d commit 4f0650d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions plugs/template/page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ async function instantiatePageTemplate(
templateName: string,
intoCurrentPage: string | undefined,
askName: boolean,
customData: any = undefined,
) {
const templateText = await space.readPage(templateName!);

Expand All @@ -107,6 +108,7 @@ async function instantiatePageTemplate(
created: "",
lastModified: "",
perm: "rw",
data: customData,
};
// Just used to extract the frontmatter
const { frontmatter } = await renderTemplate(
Expand Down

0 comments on commit 4f0650d

Please sign in to comment.