You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
46 lines
965 B
46 lines
965 B
{% extends('layout.njk') %}
|
|
|
|
{% block main %}
|
|
|
|
{% set posts = pageQuery.find({ parent: '/', deep: 0, orderBy: [ '-date_published' ], limit: 50, filter: { view: { _eq: 'post.njk' } } }) %}
|
|
|
|
<div class="">
|
|
<blog-posts></blog-posts>
|
|
</div>
|
|
|
|
<noscript>
|
|
{% for post in posts %}
|
|
<a class="post" href="{{ post.path }}">
|
|
<h2 class="post__title">
|
|
{{ post.title }}
|
|
</h2>
|
|
|
|
<time>
|
|
{{ post.date_published }}
|
|
</time>
|
|
|
|
{% if post.excerpt %}
|
|
<div class="post__excerpt">
|
|
{{ post.excerpt }}
|
|
</div>
|
|
{% endif %}
|
|
</a>
|
|
{% endfor %}
|
|
</noscript>
|
|
|
|
{% endblock %}
|
|
|
|
{% block addFooter %}
|
|
<script defer src="{{ asset('/js/blog.js') }}"></script>
|
|
<script defer>
|
|
$(function() {
|
|
riot.register('blog-posts', blogPosts)
|
|
|
|
// mount component
|
|
riot.mount('blog-posts', {
|
|
'jobs': {{ posts | raw }},
|
|
})
|
|
})
|
|
</script>
|
|
</script>
|
|
{% endblock %} |