davidhampgonsalves / hugo-black-and-light-theme

A High contrast, text oriented, performant and Javascript-free theme for Hugo.
https://themes.gohugo.io/themes/hugo-black-and-light-theme/
GNU General Public License v3.0
189 stars 94 forks source link

option to disable webfonts? #12

Closed cardi closed 6 years ago

cardi commented 6 years ago

Great theme!

What do you think of using a conditional to disable web fonts via config.toml (if you prefer to have web fonts enabled by default)?

e.g., from: https://github.com/davidhampgonsalves/hugo-black-and-light-theme/blob/3884985737ebc654314a372914e11a27d666c7b9/layouts/partials/header.html#L12

to something like:

{{ if not .Site.Params.disableWebFonts }}
<link href='https://fonts.googleapis.com/css?family=Open+Sans:400|Old+Standard+TT:400' rel='stylesheet' type='text/css'>
{{ end }}

Thus a site can have its web fonts disabled explicitly.

davidhampgonsalves commented 6 years ago

Yea good idea, the disableWebFonts param is now on master.

cardi commented 6 years ago

Great, thanks!