feat(): display dynamic pages title and description

This commit is contained in:
kendo5731 2016-02-06 15:21:59 +01:00
parent f4d8ac34df
commit b9047b4cf3
3 changed files with 8 additions and 4 deletions

View File

@ -6,10 +6,10 @@ A theme for [Hugo](https://gohugo.io/), inspired by Atom editor.
This repo is a work in progress, there is still work to do, contributions are welcome !
- Support "dynamic" titles and descriptions
- Uglify CSS and Javascript
- Add integration with Disqus
- Add integration with Google Analytics
- Add a "Home" link in the top of the menu
- Add custom 404.html
- Support for code highlighting
- Conventional CHANGELOG.md

View File

@ -2,8 +2,12 @@
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
<meta name="author" content="{{ with .Site.Params.name }}{{ . }}{{ end }}">
<meta name="description" content="{{ with .Site.Params.name }}{{ . }}{{ end }}">
{{ if isset . "Description" }}
<meta name="description" content="{{ .Description }}">
{{ else }}
<meta name="description" content="{{ with .Site.Params.description }}{{ . }}{{ end }}">
{{ end }}
<title>{{ .Title }}</title>
{{ .Hugo.Generator }}
<title>{{ .Site.Title }}</title>
<link href="https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700" rel="stylesheet" type="text/css">
<link href="{{ .Site.BaseURL }}css/theme.css" rel="stylesheet" type="text/css">

View File

@ -1,6 +1,6 @@
<nav class="col-md-3">
<div id="last-posts" class="open">
<h3 data-open="last-posts">Aubm.net - Les derniers articles</h3>
<h3 data-open="last-posts">{{ .Site.Title }} - Les derniers articles</h3>
<ul>
{{ range last 10 .Site.Pages }}
<li><a href="{{ .Permalink }}">{{ .Title }}</a></li>