Hey Folks!
I’m trying to create a new theme. It was going awesome until this issue came up. Whenever I try to put {{ .Site.BaseURL }} in any CSS file, it renders “< no value >” in the place (without quotes). Moreover, the CSS in which I use {{ $variable.UniqueID }}, are not even rendered at all.
Summing things up; Hugo not rendering .Site.BaseURL, and CSS with $p.UniqueID.
I think this might arise from a previous issue in the where I have defined block as:
{{ block “title” . }}
{{ .Site.Title}}
{{ end }}
In my single.html file, I have redefined title to replace it with:
{{ define “title”}}
{{ .Title }} – {{ .Site.Title }}
{{ end }}
(The – above is actually &ndash) And the title can be printed anywhere except on the browser tab where it should be. Neither Site title nor page title. Just: localhost:xxxx/pageName shows up on the browser tab.
Another thing to note is that whenever I use printf function, it renders the correct title & sitebaseURL value (with no other content of course).
Neither the site title nor the page title shows up. I am attaching some pictures if that can help.
Baseof.html Code
Head.html Code
HTML Code
CSS Code
Final Result