From abc42cf82d2ce787acf21f59c80da5fa32a10cbe Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Fri, 3 Jul 2015 01:37:02 +0100 Subject: [PATCH] Don't have to use excerpt block --- source/blog.html | 40 +++++++++++++++++++++------------------- 1 file changed, 21 insertions(+), 19 deletions(-) diff --git a/source/blog.html b/source/blog.html index b9097b75..aa8355e5 100644 --- a/source/blog.html +++ b/source/blog.html @@ -10,27 +10,29 @@ use: {% block body_classes %}page--blog page--blog__list{% endblock %} {% block content %} -

Blog

+

Blog

-{% for post in page.pagination.items %} -
- {% include 'post-header' with { page: post, title_tag: 'h2' } %} + {% for post in page.pagination.items %} +
+ {% include 'post-header' with { page: post, title_tag: 'h2' } %} - {% if post.blocks.excerpt %} - {{ post.blocks.excerpt|raw }} - {% endif %} - Read more → -
-{% endfor %} + {% if post.blocks.excerpt %} + {{ post.blocks.excerpt|raw }} + {% else %} + {{ post.blocks.content|raw|split(' ')|slice(0,50)|join(' ')|raw }} … + {% endif %} + Read more → +
+ {% endfor %} -{% if page.pagination.previous_page or page.pagination.next_page %} - -{% endif %} {% endblock %}