hacks-guide-minimal-mistake.../_layouts/home.html
2016-02-22 16:46:49 -05:00

17 lines
No EOL
628 B
HTML

---
layout: default
---
<div id="index">
<h3><a href="{{ absurl }}/posts/">Recent Posts</a></h3>
{% for post in site.posts limit:5 %}
<article>
{% if post.link %}
<h2 class="link-post"><a href="{{ absurl }}{{ post.url }}" title="{{ post.title }}">{{ post.title }}</a> <a href="{{ post.link }}" target="_blank" title="{{ post.title }}"><i class="fa fa-link"></i></a></h2>
{% else %}
<h2><a href="{{ absurl }}{{ post.url }}" title="{{ post.title }}">{{ post.title }}</a></h2>
<p>{{ post.excerpt | strip_html | truncate: 160 }}</p>
{% endif %}
</article>
{% endfor %}
</div><!-- /#index -->