diff --git a/layouts/partials/js.html b/layouts/partials/js.html index fcd88ef..926550a 100644 --- a/layouts/partials/js.html +++ b/layouts/partials/js.html @@ -1,5 +1,9 @@ {{ $js := resources.Get "js/main.js" }} {{ with $js }} -{{ $secureJS := . | js.Build | resources.Minify | resources.Fingerprint }} +{{ $secureJS := . | js.Build }} +{{ if not $.Site.Params.debug }} + {{ $secureJS = $secureJS | minify }} +{{ end }} +{{ $secureJS = $secureJS | fingerprint }} {{ end }} diff --git a/layouts/partials/style.html b/layouts/partials/style.html index e4dbc70..08a1639 100644 --- a/layouts/partials/style.html +++ b/layouts/partials/style.html @@ -1,2 +1,9 @@ - {{ $style := resources.Get "styles/main.sass" | toCSS | minify | fingerprint }} - +{{ $style := resources.Get "styles/main.sass" }} +{{ with $style }} +{{ $styleCSS := . | toCSS }} +{{ if not $.Site.Params.debug }} + {{ $styleCSS = $styleCSS | minify }} +{{ end }} +{{ $styleCSS = $styleCSS | fingerprint }} + +{{ end }}