Skip to content

Commit

Permalink
✨ feat: 支持自定义页面
Browse files Browse the repository at this point in the history
  • Loading branch information
白云苍狗 committed Dec 30, 2022
1 parent e403445 commit 6b06c34
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
9 changes: 9 additions & 0 deletions package/hexo-theme-async/layout/custom.ejs
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<% let banner = page.banner || {}; %>
<%- partial('./_partial/main', {
banner: partial('./_partial/banner', {
...theme.banner.default,
bannerTitle: page.title,
...banner
}),
content: page.content
}) %>
2 changes: 2 additions & 0 deletions package/hexo-theme-async/layout/page.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,6 @@
<%- partial('./tag') %>
<%} else if (page.type=='category'){%>
<%- partial('./category') %>
<%} else { %>
<%- partial('./custom') %>
<%}%>

0 comments on commit 6b06c34

Please sign in to comment.