0
Hexo 블로그를 둘러보기. 각 카테고리의 모든 게시물을 나열하는 카테고리 페이지가 있습니다. 그러나 하나의 범주에 대해 별도의 페이지를 필요로합니다. 여기서 구문에 익숙하지 않습니다. '추천'카테고리에 대해 어떻게 필터링합니까?헥소로 카테고리별로 게시물을 얻는 방법은 무엇입니까?
<div class="archives-wrap" style="margin: 0px;">
<div class="archives-category-wrap">
<blockquote>
<% if(site.categories.length) { %>
<%- list_categories(site.categories) %>
<% } %>
</blockquote>
</div>
<% site.categories.sort('name').map(function(category){ %>
<div class="archives-wrap">
<div class="archive-year-wrap" id="<%= category.name %>">
<h1 class="archive-category"><%= category.name %></h1>
</div>
<div class="archives">
<% category.posts.sort('-date').map(function(post, i){ %>
<%- partial('_partial/archive-post', {post: post, index: true}) %>
<% if (post.subtitle && post.subtitle.length) { %>
<h3 class="post-subtitle">
<%- post.subtitle %>
</h3>
<% } %>
<% }) %>
</div>
</div>
<% }) %>