From fa6d517cad2160f983c492ff6edac722f48c041e Mon Sep 17 00:00:00 2001 From: Dmitry Kolosov Date: Sun, 29 May 2022 18:03:39 +0300 Subject: [PATCH] add locale param for multilang #155 --- exampleSiteMultilingual/config.toml | 4 ++++ layouts/_default/baseof.html | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/exampleSiteMultilingual/config.toml b/exampleSiteMultilingual/config.toml index e8cfc91..d4cb131 100644 --- a/exampleSiteMultilingual/config.toml +++ b/exampleSiteMultilingual/config.toml @@ -21,6 +21,7 @@ readMore = false readNextPosts = 2 copyCodeButton = true rssAsSocialIcon = true +locale = "en-us" # Graphcomment support graphcommentId = "" @@ -81,6 +82,9 @@ name = "Archiwum" url = "/posts/" weight = 3 +[[languages.pl.params]] +locale = "pl-pl" + [taxonomies] category = "categories" tag = "tags" diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index a0ea13d..52d8086 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -3,7 +3,7 @@ {{ if eq site.Params.style "dark-without-switcher" }} {{ $dataTheme = "dark" }} {{ end }} - + {{ block "head" . }} {{ partial "head.html" . }}