Skip to content

Commit

Permalink
#28 add blog page initial
Browse files Browse the repository at this point in the history
  • Loading branch information
tomheller committed Sep 15, 2018
1 parent 7d94697 commit 0d9414a
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 0 deletions.
7 changes: 7 additions & 0 deletions archetypes/blog.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
title: "{{ replace .Name "-" " " | title }}"
description: "Metadescription of the blogpost"
date: {{ .Date }}
draft: true
---

36 changes: 36 additions & 0 deletions layouts/_default/list.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{{ define "content" }}
<div class="jumbotron homepage__hero">
<div class="container">
<h1 class="h1">{{ .Title }}</h1>
</div>
</div>

<main>
{{if .Content}}
<div class="section">
<div class="container">
{{.Content}}
</div>
</div>
{{ end }}

<div class="section">
<div class="container">

{{if .Pages }}
<ul>
<!-- Ranges through content/{taxonomy}/*.md -->
{{ range .Pages }}
<li>
<a href="{{.Permalink}}">{{.Date.Format "2006-01-02"}} | {{.Title}}</a>
</li>
{{ end }}
</ul>
{{ else }}
<p>{{ .Params.emptyText }}</p>
{{ end }}
</div>
</div>

</main>
{{ end }}

0 comments on commit 0d9414a

Please sign in to comment.