Przeglądaj źródła

Don't repeat title in <title> tag on the home page

Jakub Kucharski 8 lat temu
rodzic
commit
61243733ec
1 zmienionych plików z 5 dodań i 1 usunięć
  1. 5
    1
      layouts/partials/head.html

+ 5
- 1
layouts/partials/head.html Wyświetl plik

@@ -8,7 +8,11 @@
8 8
   <!-- Enable responsiveness on mobile devices-->
9 9
   <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1">
10 10
 
11
-  <title> {{ .Title }} &middot; {{ .Site.Title }} </title>
11
+  {{ if .IsHome }}
12
+  <title>{{ .Site.Title }}</title>
13
+  {{ else }}
14
+  <title>{{ .Title }} &middot; {{ .Site.Title }}</title>
15
+  {{ end }}
12 16
 
13 17
   <!-- CSS -->
14 18
   <link rel="stylesheet" href="{{ .Site.BaseURL }}css/poole.css">