Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/EmielH/tale-hugo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEmiel Hollander <EmielH@users.noreply.github.com>2018-08-25 11:47:30 +0300
committerEmiel Hollander <EmielH@users.noreply.github.com>2018-08-25 11:47:30 +0300
commit40be04b726f555d849da68b738f31365a057cf77 (patch)
tree707eedce88bfd3e33d9a5ebfd78cbe149e34c345 /layouts
parentf569443641b15ac288e836a6d5ebe36465fa0141 (diff)
Improve SCSS processing
Diffstat (limited to 'layouts')
-rw-r--r--layouts/partials/head.html5
1 files changed, 4 insertions, 1 deletions
diff --git a/layouts/partials/head.html b/layouts/partials/head.html
index a67e7a3..99546be 100644
--- a/layouts/partials/head.html
+++ b/layouts/partials/head.html
@@ -18,7 +18,10 @@
</title>
<!-- CSS -->
- {{ $style := resources.Get "scss/tale.scss" | toCSS | minify }}
+ {{- $inServerMode := .Site.IsServer }}
+ {{- $cssTarget := "css/style.css" }}
+ {{- $cssOptions := cond ($inServerMode) (dict "targetPath" $cssTarget "enableSourceMap" true) (dict "targetPath" $cssTarget "outputStyle" "compressed") }}
+ {{- $style := resources.Get "scss/tale.scss" | toCSS $cssOptions }}
<link rel="stylesheet" href="{{ $style.RelPermalink }}">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Libre+Baskerville:400,400i,700">