<% var sections = page.body ? page.body : theme.body; %> <% sections.forEach(function(sectionName){ %> <% if (sectionName == 'article') { %>
<%- partial('meta', {post: post, position: 'header'}) %>
<%- post.content %>
<% if(post.layout == 'post'){ %> <%- partial('meta', {post: post, position: 'footer'}) %> <% } %> <% if(post.prev || post.next){ %>
<% if(post.prev){ %>
 <%- __('post.prev_page') %>

<% if (post.prev.tags && post.prev.tags.length && post.prev.tags.each) { %> <% var items = []; post.prev.tags.each(function(item){ items.push('' + item.name + ''); }); %>
<%- items.join(' ') %>
<% } %>
<% } %> <% if(post.next){ %>
<%} %>
<%} %>
<% } else if (sectionName == 'comments') { %> <%- partial('../_third-party/' + sectionName) %> <% } else { %> <% theme.sidebar.forEach(function(item){ %> <% if (item.widget == sectionName) { %> <%- partial('../_widget/' + item.widget, {item: item}) %> <% } %> <% }) %> <% } %> <% }) %> <% if (page.mathjax){ %> <%- partial('mathjax') %> <% } %> <% if (page.layout == 'post'){ %> <% } %>