implements tailwind v4 and removes scss
This commit is contained in:
23
layouts/partials/css.html
Normal file
23
layouts/partials/css.html
Normal file
@ -0,0 +1,23 @@
|
||||
{{ with (templates.Defer (dict "key" "global")) }}
|
||||
{{ $t := debug.Timer "tailwindcss" }}
|
||||
{{ with resources.Get "css/styles.css" }}
|
||||
{{ $opts := dict
|
||||
"inlineImports" true
|
||||
"optimize" (not hugo.IsDevelopment)
|
||||
}}
|
||||
{{ with . | css.TailwindCSS $opts }}
|
||||
{{ if hugo.IsDevelopment }}
|
||||
<link rel="stylesheet" href="{{ .RelPermalink }}" />
|
||||
{{ else }}
|
||||
{{ with . | minify | fingerprint }}
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="{{ .RelPermalink }}"
|
||||
integrity="{{ .Data.Integrity }}"
|
||||
crossorigin="anonymous" />
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ $t.Stop }}
|
||||
{{ end }}
|
Reference in New Issue
Block a user