Skip to content
Snippets Groups Projects
Commit 73c250a1 authored by micressor's avatar micressor Committed by micressor
Browse files

Base briar template optimization

parent 0d1886dd
No related branches found
No related tags found
1 merge request!24Feature hugo migration
<!DOCTYPE html> <!DOCTYPE html>
<html lang="{{ .Site.LanguageCode }}"> <html lang="{{ .Site.LanguageCode }}">
{{- partial "head.html" . -}} {{- partial "head.html" . -}}
<body> <body>
<div id="wrapper"> <div id="wrapper">
{{- partial "header.html" . -}} {{- partial "header.html" . -}}
<div id="container"> <div id="container">
<div id="content"> <div id="content">
{{- block "main" . }}{{- end }} {{- block "main" . }}{{- end }}
</div>
</div>
{{- partial "footer.html" . -}}
</div> </div>
</body> </div>
{{- partial "footer.html" . -}}
</div>
</body>
</html> </html>
{{ define "main" }} {{ define "main" }}
<h1>{{ with .Title }} {{ . }} {{ else }} {{ .Site.Title }} {{ end }}</h1> <h1>{{ with .Title }} {{ . }} {{ else }} {{ .Site.Title }} {{ end }}</h1>
{{ range first 1 .Pages.ByDate.Reverse }} {{ range first 1 .Pages.ByDate.Reverse }}
<h3 itemprop="headline" class="blog-post-title"> <h3 itemprop="headline" class="blog-post-title">
<a href="{{.Permalink}}">{{.Title}}</a> <a href="{{.Permalink}}">{{.Title}}</a>
</h3> </h3>
<p class="blog-post-meta">{{.Date.Format "2006-01-02"}} <p class="blog-post-meta">{{.Date.Format "2006-01-02"}}
{{ if (isset .Params "author") }} {{ if (isset .Params "author") }}
by {{ markdownify .Params.author }} by {{ markdownify .Params.author }}
{{ end }} {{ end }}
</p> </p>
{{ end }} {{ end }}
{{ .Content }} {{ .Content }}
{{ end }} {{ end }}
{{ define "main" }} {{ define "main" }}
<h1>{{ with .Title }} {{ . }} {{ else }} {{ .Site.Title }} {{ end }}</h1> <h1>{{ with .Title }} {{ . }} {{ else }} {{ .Site.Title }} {{ end }}</h1>
{{ range first 10 .Pages.ByDate.Reverse }} {{ range first 10 .Pages.ByDate.Reverse }}
<h3 itemprop="headline" class="blog-post-title"> <h3 itemprop="headline" class="blog-post-title">
<a href="{{.Permalink}}">{{.Title}}</a> <a href="{{.Permalink}}">{{.Title}}</a>
</h3> </h3>
<p class="blog-post-meta">{{.Date.Format "2006-01-02"}} <p class="blog-post-meta">{{.Date.Format "2006-01-02"}}
{{ if (isset .Params "author") }} {{ if (isset .Params "author") }}
by {{ markdownify .Params.author }} by {{ markdownify .Params.author }}
{{ end }} {{ end }}
</p> </p>
{{ end }} {{ end }}
{{ .Content }} {{ .Content }}
{{ end }} {{ end }}
{{ define "main" }} {{ define "main" }}
<h2>{{ .Title }}</h2> <h2>{{ .Title }}</h2>
{{ .Content }} {{ .Content }}
{{ end }} {{ end }}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment