forked from artemsheludko/flexible-jekyll
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
executable file
·19 lines (18 loc) · 868 Bytes
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
---
layout: main
---
{% for post in paginator.posts %}
<article class="post">
{% if post.img %}
<a class="post-thumbnail" style="background-image: url({{"/assets/img/" | prepend: site.baseurl | append : post.img}})" href="{{post.url | prepend: site.baseurl}}"></a>
{% else %}
{% endif %}
<div class="post-content">
<h2 class="post-title"><a href="{{post.url | prepend: site.baseurl}}">{{post.title}}</a></h2>
<p>{{ post.content | strip_html | truncatewords: 15 }}</p>
<span class="post-date">{{post.date | date: '%Y, %b %d'}} — </span>
<span class="post-words">{% capture words %}{{ post.content | number_of_words }}{% endcapture %}{% unless words contains "-" %}{{ words | plus: 250 | divided_by: 250 | append: " minute read" }}{% endunless %}</span>
</div>
</article>
{% endfor %}
{% include pagination.html %}