When using Hugo, is it possible to display a data template using the .Title
function? For example, here is my data template function <p>{{.Site.Data.config.TextOne}}</p>
. It grabs the string TextOne
from my data template file in the directory /data. However, I want to be able to use the title of the page or a variable in the place of .TextOne
. Kind of this {{.Site.Data.config.Title}}
. That of course doesn’t work.
What might be alternatives or solutions to this request?