diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/templates.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/templates.ts b/src/templates.ts index 0a0de83..a134723 100644 --- a/src/templates.ts +++ b/src/templates.ts @@ -17,7 +17,7 @@ function addMenu( child: cheerio.Cheerio<cheerio.AnyNode>, ) { parent.empty(); - for (const link of config.extra.main_menu) { + for (const link of config.menus.main) { parent.append(child.clone().attr("href", link.url).text(link.name)); } } @@ -57,10 +57,10 @@ async function renderHomepage(posts: Array<Post>): Promise<string> { $(".title").addClass("p-name").addClass("u-url"); $("#content").html(await marked.parse(file.content)); const $feed = $(".h-feed"); - const $tpl = $(".h-entry").remove(); + const $entry = $(".h-entry").remove(); for (const post of posts) { - const $post = $tpl.clone(); + const $post = $entry.clone(); $post.find(".p-name").text(post.title); $post.find(".u-url").attr("href", post.url); $post |