Merge pull request #487 from TheGroundZero/patch-8

Fix #482 - ToCSS
This commit is contained in:
Djordje Atlialp 2024-10-17 23:36:56 +02:00 committed by GitHub
commit f26481f3fa
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -22,9 +22,11 @@
{{ end }}
<!-- CSS -->
{{ $options := (dict "targetPath" "main.css" "outputStyle" "compressed" "enableSourceMap" true) }}
{{ $style := resources.Get "scss/main.scss" | resources.ToCSS $options | resources.Fingerprint }}
<link rel="stylesheet" href="{{ $style.RelPermalink }}" integrity="{{ $style.Data.Integrity }}">
{{ $opts := dict "transpiler" "libsass" "targetPath" "main.css" "outputStyle" "compressed" "enableSourceMap" true }}
{{ with resources.Get "scss/main.scss" | toCSS $opts | minify | fingerprint }}
<link rel="stylesheet" href="{{ .RelPermalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous">
{{ end }}
{{ range $val := $.Site.Params.customCSS }}
{{ if gt (len $val) 0 }}