Use site.Home.Permalink instead of param

This commit is contained in:
C. Lente 2023-02-09 17:31:27 -03:00
parent 045c2e3495
commit 6d88b28c14
No known key found for this signature in database
GPG Key ID: B0B503C26E05781B
2 changed files with 5 additions and 5 deletions

View File

@ -28,16 +28,16 @@ DefaultContentLanguage = "en"
contentDir = "content" contentDir = "content"
weight = 1 weight = 1
[languages.en.params] [languages.en.params]
home = '/' # You can use markdown here if you want to link somewhere
madeWith = '[Feito de pedra](/posts/sites-de-pedra)' # You can use markdown here if you want to link somewhere madeWith = '[Feito de pedra](/posts/sites-de-pedra)'
[languages.pt] [languages.pt]
title = "Site Exemplo" title = "Site Exemplo"
languageName = "Português 🇧🇷" languageName = "Português 🇧🇷"
contentDir = "content.pt" contentDir = "content.pt"
weight = 2 weight = 2
[languages.pt.params] [languages.pt.params]
home = '/pt' # You can use markdown here if you want to link somewhere
madeWith = '[Feito de pedra](/posts/sites-de-pedra)' # You can use markdown here if you want to link somewhere madeWith = '[Feito de pedra](/posts/sites-de-pedra)'
[params] [params]
# The "description" of your website. This is used in the meta data of your generated html. # The "description" of your website. This is used in the meta data of your generated html.

View File

@ -1,2 +1,2 @@
<a href="{{ .Site.Language.Params.params.home }}" class="title"><h2>{{ .Site.Title }}</h2></a> <a href="{{ site.Home.Permalink }}" class="title"><h2>{{ .Site.Title }}</h2></a>
<nav>{{- partial "nav.html" . -}}</nav> <nav>{{- partial "nav.html" . -}}</nav>