Fix relURL for custom_css (#252)

The way relURL was used meant that one needed to preface the custom_css
entries with a slash, or the href would be incorrectly set to
subdircss/mycss.css rather than subdir/css/mycss.css, in the case of
a baseURL in a subdir.

Co-authored-by: Nick White <git@njw.name>
This commit is contained in:
nickjwhite 2020-06-03 14:16:59 +00:00 committed by GitHub
parent 0cb10e19cc
commit cfbd40cd86
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -20,7 +20,7 @@
{{ end }} {{ end }}
{{ range .Site.Params.custom_css }} {{ range .Site.Params.custom_css }}
<link rel="stylesheet" href="{{ relURL ($.Site.BaseURL) }}{{ . }}"> <link rel="stylesheet" href="{{ relURL (.) }}">
{{ end }} {{ end }}
{{ block "favicon" . }} {{ block "favicon" . }}