seo improvement with titles h1/h4
This commit is contained in:
21
hugo.toml
21
hugo.toml
@@ -38,9 +38,8 @@ ignoreLogs = ["warning-goldmark-raw-html"]
|
|||||||
site = "@mistergeekfrance"
|
site = "@mistergeekfrance"
|
||||||
creator = "@mistergeekfrance"
|
creator = "@mistergeekfrance"
|
||||||
|
|
||||||
# Facebook
|
facebook_page = "mistergeekfrance"
|
||||||
facebook_page = "mistergeek.fr"
|
# youtube_channel = "UCXXXXXXXXXXXXXXXXXXX"
|
||||||
youtube_channel = "UCXXXXXXXXXXXXXXXXXXX"
|
|
||||||
|
|
||||||
# Search Engine Verification
|
# Search Engine Verification
|
||||||
# google_verification = "your-google-verification-code"
|
# google_verification = "your-google-verification-code"
|
||||||
@@ -48,14 +47,14 @@ ignoreLogs = ["warning-goldmark-raw-html"]
|
|||||||
# yandex_verification = "your-yandex-verification-code"
|
# yandex_verification = "your-yandex-verification-code"
|
||||||
|
|
||||||
# Local SEO
|
# Local SEO
|
||||||
[params.seo.local]
|
# [params.seo.local]
|
||||||
enabled = true
|
# enabled = true
|
||||||
country = "FR"
|
# country = "FR"
|
||||||
language = "fr"
|
# language = "fr"
|
||||||
region = "Île-de-France"
|
# region = "Île-de-France"
|
||||||
city = "Paris"
|
# city = "Paris"
|
||||||
latitude = "48.8566"
|
# latitude = "48.8566"
|
||||||
longitude = "2.3522"
|
# longitude = "2.3522"
|
||||||
|
|
||||||
# Rich snippets
|
# Rich snippets
|
||||||
enable_search_box = true
|
enable_search_box = true
|
||||||
|
|||||||
@@ -1,9 +1,9 @@
|
|||||||
{{ define "main" }}
|
{{ define "main" }}
|
||||||
|
|
||||||
|
<!-- layouts/_default/list.html -->
|
||||||
<div class="section-sm bg-gray-lighter">
|
<div class="section-sm bg-gray-lighter">
|
||||||
<div class="container text-center">
|
<div class="container text-center">
|
||||||
<h1 class="font-family-playfair">{{ .Site.Title }}</h1>
|
<h1 class="font-family-playfair">{{ .Site.Title }}</h1>
|
||||||
<p class="mt-3">{{ .Site.Params.seo.description }}</p>
|
|
||||||
</div><!-- end container -->
|
</div><!-- end container -->
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -29,25 +29,14 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="mt-4">
|
<div class="mt-4">
|
||||||
<div class="d-flex justify-content-between mb-2">
|
<div class="d-flex justify-content-between mb-2">
|
||||||
<div class="d-inline-flex">
|
<!-- Display category -->
|
||||||
{{ if .Params.categories }}
|
{{ partial "categories-first.html" . }}
|
||||||
{{ range $index, $category := .Params.categories }}
|
|
||||||
{{ if $index }}, {{ end }}
|
|
||||||
{{ if and (eq (printf "%T" $category) "string") }}
|
|
||||||
<a class="font-family-poppins font-small fw-medium uppercase" href="/categories/{{ $category | urlize }}">{{ $category }}</a>
|
|
||||||
{{ else if and (eq (printf "%T" $category) "map") }}
|
|
||||||
{{ if $category.name }}
|
|
||||||
<a class="font-family-poppins font-small fw-medium uppercase" href="/categories/{{ $category.name | urlize }}">{{ $category.name }}</a>
|
|
||||||
{{ end }}
|
|
||||||
{{ end }}
|
|
||||||
{{ end }}
|
|
||||||
{{ end }}
|
|
||||||
</div>
|
|
||||||
<div class="d-inline-flex">
|
<div class="d-inline-flex">
|
||||||
<span class="font-small">{{ .Date.Format "02/07/2006" }}</span>
|
<span class="font-small">{{ .Date.Format "02/07/2006" }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<h4><a class="text-link-1" href="{{ .RelPermalink }}">{{ .Title }}</a></h4>
|
<h2><a class="text-link-1" href="{{ .RelPermalink }}">{{ .Title }}</a></h2>
|
||||||
{{ if .Params.excerpt }}
|
{{ if .Params.excerpt }}
|
||||||
<p>{{ .Params.excerpt }}</p>
|
<p>{{ .Params.excerpt }}</p>
|
||||||
{{ else if .Summary }}
|
{{ else if .Summary }}
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
{{ end }}
|
{{ end }}
|
||||||
{{ with .Params.categories }}
|
{{ with .Params.categories }}
|
||||||
{{ range . }}
|
{{ range . }}
|
||||||
<li>dans <a href="/categories/{{ . | urlize }}">{{ . }}</a></li>
|
<li>dans <a href="/{{ . | urlize }}">{{ . }}</a></li>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
<li> le {{ .Date.Format "02/01/2006" }}</li>
|
<li> le {{ .Date.Format "02/01/2006" }}</li>
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
<div class="section-sm bg-gray-lighter">
|
<div class="section-sm bg-gray-lighter">
|
||||||
<div class="container text-center">
|
<div class="container text-center">
|
||||||
<h3 class="font-family-playfair">{{ .Title }}</h3>
|
<h1 class="font-family-playfair">{{ .Title }}</h1>
|
||||||
<p class="mt-3">Cette page répertorie toutes les catégories de notre site, offrant une vue d'ensemble structurée de notre contenu.</p>
|
<p class="mt-3">Cette page répertorie toutes les catégories de notre site, offrant une vue d'ensemble structurée de notre contenu.</p>
|
||||||
</div><!-- end container -->
|
</div><!-- end container -->
|
||||||
</div>
|
</div>
|
||||||
@@ -17,7 +17,7 @@
|
|||||||
{{ range $.Site.Data.wordpress.categories }}
|
{{ range $.Site.Data.wordpress.categories }}
|
||||||
<div class="mb-5">
|
<div class="mb-5">
|
||||||
<div class="mt-4">
|
<div class="mt-4">
|
||||||
<h4><a class="text-link-1" href="{{ .link | relURL }}">{{ .name }}</a></h4>
|
<h2><a class="text-link-1" href="{{ .link | relURL }}">{{ .name }}</a></h2>
|
||||||
<p>{{ .description | safeHTML }}</p>
|
<p>{{ .description | safeHTML }}</p>
|
||||||
<div class="mt-3">
|
<div class="mt-3">
|
||||||
<a class="button-text-1" href="{{ .link | relURL }}">Voir la catégorie</a>
|
<a class="button-text-1" href="{{ .link | relURL }}">Voir la catégorie</a>
|
||||||
|
|||||||
@@ -1,9 +1,10 @@
|
|||||||
{{ define "main" }}
|
{{ define "main" }}
|
||||||
{{ $defaultCategory := "General" }}
|
|
||||||
{{ if .Site.Params.defaultCategory }}{{ $defaultCategory = .Site.Params.defaultCategory }}{{ end }}
|
<!-- layouts/index.html -->
|
||||||
<div class="section-sm bg-gray-lighter">
|
<div class="section-sm bg-gray-lighter">
|
||||||
<div class="container text-center">
|
<div class="container text-center">
|
||||||
<h3 class="font-family-playfair">{{ .Site.Title }} blog.</h3>
|
<h1 class="font-family-playfair">{{ .Site.Title }}</h1>
|
||||||
|
<p class="mt-3">{{ .Site.Params.seo.description }}</p>
|
||||||
</div><!-- end container -->
|
</div><!-- end container -->
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -27,31 +28,14 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="mt-4">
|
<div class="mt-4">
|
||||||
<div class="d-flex justify-content-between mb-2">
|
<div class="d-flex justify-content-between mb-2">
|
||||||
<div class="d-inline-flex">
|
<!-- Display category -->
|
||||||
{{ if .Params.categories }}
|
{{ partial "categories-first.html" . }}
|
||||||
{{ range $index, $category := .Params.categories }}
|
|
||||||
{{ if $index }}, {{ end }}
|
|
||||||
{{ if and (eq (printf "%T" $category) "string") }}
|
|
||||||
<a class="font-family-poppins font-small fw-medium uppercase" href="/categories/{{ $category | urlize }}">{{ $category }}</a>
|
|
||||||
{{ else if and (eq (printf "%T" $category) "map") }}
|
|
||||||
{{ if $category.name }}
|
|
||||||
<a class="font-family-poppins font-small fw-medium uppercase" href="/categories/{{ $category.name | urlize }}">{{ $category.name }}</a>
|
|
||||||
{{ else }}
|
|
||||||
<a class="font-family-poppins font-small fw-medium uppercase" href="#">{{ $defaultCategory }}</a>
|
|
||||||
{{ end }}
|
|
||||||
{{ else }}
|
|
||||||
<a class="font-family-poppins font-small fw-medium uppercase" href="#">{{ $defaultCategory }}</a>
|
|
||||||
{{ end }}
|
|
||||||
{{ end }}
|
|
||||||
{{ else }}
|
|
||||||
<a class="font-family-poppins font-small fw-medium uppercase" href="#">{{ $defaultCategory }}</a>
|
|
||||||
{{ end }}
|
|
||||||
</div>
|
|
||||||
<div class="d-inline-flex">
|
<div class="d-inline-flex">
|
||||||
<span class="font-small">{{ .Date.Format "02/07/2006" }}</span>
|
<span class="font-small">{{ .Date.Format "02/07/2006" }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<h4><a class="text-link-1" href="{{ .Permalink }}">{{ .Title }}</a></h4>
|
<h2><a class="text-link-1" href="{{ .Permalink }}">{{ .Title }}</a></h2>
|
||||||
{{ if .Params.excerpt }}
|
{{ if .Params.excerpt }}
|
||||||
<p>{{ .Params.excerpt }}</p>
|
<p>{{ .Params.excerpt }}</p>
|
||||||
{{ else if .Summary }}
|
{{ else if .Summary }}
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
<div class="section-sm bg-gray-lighter">
|
<div class="section-sm bg-gray-lighter">
|
||||||
<div class="container text-center">
|
<div class="container text-center">
|
||||||
<h3 class="font-family-playfair">{{ .Title }}</h3>
|
<h1 class="font-family-playfair">{{ .Title }}</h1>
|
||||||
<p class="mt-2">Retrouvez toutes les pages utiles du site ici.</p>
|
<p class="mt-2">Retrouvez toutes les pages utiles du site ici.</p>
|
||||||
</div><!-- end container -->
|
</div><!-- end container -->
|
||||||
</div>
|
</div>
|
||||||
@@ -24,7 +24,7 @@
|
|||||||
<!-- Blog Post box -->
|
<!-- Blog Post box -->
|
||||||
<div class="mb-5">
|
<div class="mb-5">
|
||||||
<div class="mt-4">
|
<div class="mt-4">
|
||||||
<h4><a class="text-link-1" href="{{ .RelPermalink }}">{{ .Title }}</a></h4>
|
<h2><a class="text-link-1" href="{{ .RelPermalink }}">{{ .Title }}</a></h2>
|
||||||
{{ if .Params.excerpt }}
|
{{ if .Params.excerpt }}
|
||||||
<p>{{ .Params.excerpt }}</p>
|
<p>{{ .Params.excerpt }}</p>
|
||||||
{{ else if .Summary }}
|
{{ else if .Summary }}
|
||||||
|
|||||||
13
layouts/partials/categories-first.html
Normal file
13
layouts/partials/categories-first.html
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
<div class="d-inline-flex">
|
||||||
|
{{ if .Params.categories }}
|
||||||
|
{{ with index .Params.categories 0 }}
|
||||||
|
{{ if and (eq (printf "%T" .) "string") }}
|
||||||
|
<a class="font-family-poppins font-small fw-medium uppercase" href="/{{ . | urlize }}">{{ . }}</a>
|
||||||
|
{{ else if and (eq (printf "%T" .) "map") }}
|
||||||
|
{{ if .name }}
|
||||||
|
<a class="font-family-poppins font-small fw-medium uppercase" href="/{{ .name | urlize }}">{{ .name }}</a>
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
|
{{ end }}
|
||||||
|
</div>
|
||||||
@@ -13,7 +13,7 @@
|
|||||||
{{ if .Site.Data.wordpress }}
|
{{ if .Site.Data.wordpress }}
|
||||||
{{ range $index, $element := .Site.Data.wordpress.navigation }}
|
{{ range $index, $element := .Site.Data.wordpress.navigation }}
|
||||||
<li>
|
<li>
|
||||||
<a href="/{{ $element.slug }}">{{ $element.title }}</a>
|
<a href="/pages/{{ $element.slug }}">{{ $element.title }}</a>
|
||||||
</li>
|
</li>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
{{ continue }}
|
{{ continue }}
|
||||||
{{ else if lt $count 5 }}
|
{{ else if lt $count 5 }}
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link" href="/categories/{{ $element.slug }}">{{ $element.name }}</a>
|
<a class="nav-link" href="/{{ $element.slug }}">{{ $element.name }}</a>
|
||||||
</li>
|
</li>
|
||||||
{{ $count = add $count 1 }}
|
{{ $count = add $count 1 }}
|
||||||
{{ else }}
|
{{ else }}
|
||||||
|
|||||||
Reference in New Issue
Block a user