Fix a bug

Fix a bug that CSS is not processed correctly when
`ananke_process_css = true` and `HUGO_ENV=production`.
This commit is contained in:
Yuta Nagamiya 2021-06-03 04:25:11 +09:00
parent 988c731a57
commit 34881f6f0e

View File

@ -9,7 +9,7 @@
{{ $style := . | resources.ToCSS $options | resources.PostCSS (dict "use" "postcss-cssnext") | minify }}
{{/* We fingerprint in production to ensure cache busting */}}
{{ if eq (getenv "HUGO_ENV") "production" }}
{{ $style = . | fingerprint }}
{{ $style = $style | fingerprint }}
{{ end }}
{{ with $style }}
<link rel="stylesheet" href="{{ .RelPermalink }}" >
@ -24,4 +24,4 @@
{{ range .Site.Params.custom_css }}
<link rel="stylesheet" href="{{ relURL (.) }}">
{{ end }}
{{ end }}