mirror of
https://github.com/Sped0n/bridget.git
synced 2026-04-14 10:09:31 -07:00
chore(link.html): update main style source and options to improve performance and maintainability chore(link.html): remove unused meta.html file chore(nav.html): update decrement and increment buttons to use Unicode characters for better accessibility chore(plugin/style.html): update style plugin to support inline styles for critical CSS chore(plugin/style.html): update style plugin to support minification and fingerprinting for main CSS chore(plugin/style.html): remove script plugin as it is no longer used chore(plugin/style.html): update style plugin to support inline styles for critical CSS chore(plugin/style.html): update style plugin to support minification and fingerprinting for main CSS chore(resources/imageJSON.html): update image resize options for better performance and quality
28 lines
1.0 KiB
HTML
28 lines
1.0 KiB
HTML
{{/* fingerprint */}}
|
|
{{- $fingerprint := .Scratch.Get "fingerprint" | default "" -}}
|
|
|
|
{{/* critical style */}}
|
|
{{- $style := dict "Source" "scss/critical.scss" "Fingerprint" $fingerprint -}}
|
|
{{- $options := dict "enableSourceMap" true "includePaths" (slice "node_modules") -}}
|
|
{{- $style = dict "Context" . "ToCSS" $options "Inline" true | merge $style -}}
|
|
{{- partial "plugin/style.html" $style -}}
|
|
|
|
{{/* main style */}}
|
|
{{- $style := dict "Source" "scss/style.scss" "Fingerprint" $fingerprint -}}
|
|
{{- $options := dict "targetPath" "css/style.css" "enableSourceMap" true "includePaths" (slice "node_modules") -}}
|
|
{{- $style = dict "Context" . "ToCSS" $options "Minify" hugo.IsProduction "Defer" true | merge $style -}}
|
|
{{- partial "plugin/style.html" $style -}}
|
|
|
|
{{/* main js */}}
|
|
<script type="module" src="js/main.js" defer></script>
|
|
|
|
{{/* fonts */}}
|
|
<link
|
|
rel="preload"
|
|
href="/lib/fonts/GeistVF.woff2"
|
|
as="font"
|
|
type="font/woff2"
|
|
crossorigin
|
|
/>
|
|
<link rel="preload" href="/lib/fonts/fw.svg" as="font" type="font/svg" crossorigin />
|