1
mirror of https://github.com/jakejarvis/jarv.is.git synced 2025-07-03 14:06:40 -04:00

fingerprint CSS and JS, set one week browser cache

...and LOTS of tidying partials
This commit is contained in:
2020-04-25 11:15:31 -04:00
parent d2648a68be
commit adfa73b5fc
25 changed files with 86 additions and 110 deletions

View File

@ -1,5 +1,5 @@
{{ $darkmode := resources.Get "js/dark-mode.js" }}
{{ $twemoji := resources.Get "vendor/emoji/emoji.js" | resources.ExecuteAsTemplate "vendor/emoji/emoji.min.js" . }}
{{ $js := slice $darkmode $twemoji | resources.Concat "/js/main.js" }}
<script src="{{ $js.Permalink }}"></script>
{{ $js := slice $darkmode $twemoji | resources.Concat "/js/main.js" | resources.Minify | resources.Fingerprint "sha256" }}
<script src="{{ $js.Permalink }}" integrity="{{ $js.Data.Integrity }}"></script>