Track3 / hermit

A minimal & fast Hugo theme for bloggers
https://hugo-theme-hermit.netlify.com/
MIT License
1.12k stars 304 forks source link

add background image #71

Closed pdwaggoner closed 5 years ago

pdwaggoner commented 5 years ago

Hi - sorry for another question. But I was wondering how to change the global background image for all pages. Specifically, how should I modify, themes/hermit/layouts/_default/single.html? Thanks!

Track3 commented 5 years ago

Do you mean you want all normal single page using the global image set in site's config? If that's the case, you need to modify every .Params.featuredImg and .Params.images in themes/hermit/layouts/_default/single.html like so:

This will turn all page level variables to site level. You can get the same results by add images or featuredImg filed to every single content file's front matter without modify the template.

pdwaggoner commented 5 years ago

I think this answers the question. Thanks for your response! I will give it a try.