diff --git a/exampleSite/config.toml b/exampleSite/config.toml index f5b4d3b..a722519 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -34,6 +34,9 @@ disableSitemap = false disable404 = false disableHugoGeneratorInject = false +# Set disableReadOtherPosts to true in order to hide the links to other posts. +disableReadOtherPosts = false + [permalinks] posts = "/posts/:year/:month/:title/" diff --git a/layouts/posts/single.html b/layouts/posts/single.html index 441739e..ba610ed 100644 --- a/layouts/posts/single.html +++ b/layouts/posts/single.html @@ -56,7 +56,7 @@ {{- end }} - {{ if or .NextInSection .PrevInSection }} + {{ if and (not .Site.DisableReadOtherPosts) (or .NextInSection .PrevInSection) }}