I’m a really new user to Hugo, but I created a site, added a theme, created some pages, and initially found things pretty straightforward. I’ve read the documentation a few times and I’m struggling to inject a variable (or other dynamic-ish content) into a page.
I’ve seen numerous examples using examples such as:
{{ .Title }}
but then I put them into a file, I literally see {{ .Title }}
.
I get the same results with {{ .TableOfContents }}
and {{ partial "test.md" . }}
. The only success I saw was with [Next]({{< ref "my-2nd-post.md" >}} "Here")
I see things changing when in the browser when I make the change while hugo server
is running, so I know the pages are being processed, but I’m confused as to why I’m not seeing the expected results.
I’ve even cloned the official Hugo docs and tried the same thing with them, but with a similar lack of results. For example:
---
title: Hugo Documentation
linktitle: Hugo
description: Hugo is the world's fastest static website engine. It's written in Go (aka Golang) and developed by bep, spf13 and friends.
date: 2017-02-01
publishdate: 2017-02-01
menu:
main:
parent: "section name"
weight: 01
weight: 01 #rem
draft: false
slug:
aliases: []
toc: false
layout: documentation-home
---
Hugo is the **world's fastest static website engine.** It's written in Go (aka Golang) and developed by [bep](https://github.com/bep), [spf13](https://github.com/spf13) and [friends](https://github.com/gohugoio/hugo/graphs/contributors).
{{ .Title }}
Below you will find some of the most common and helpful pages from our documentation.
Any pointers would be appreciated!
Thanks!