mirror of https://github.com/jpanther/congo.git
🥅 Catch when no JS required in bundle
parent
e67c9d0d28
commit
7992ce0035
|
@ -56,8 +56,10 @@
|
||||||
{{ $jsDark := resources.Get "js/dark.js" }}
|
{{ $jsDark := resources.Get "js/dark.js" }}
|
||||||
{{ $assets.Add "js" (slice $jsDark) }}
|
{{ $assets.Add "js" (slice $jsDark) }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ $bundleJS := $assets.Get "js" | resources.Concat "js/main.bundle.js" | resources.Minify | resources.Fingerprint "sha512" }}
|
{{ if $assets.Get "js" }}
|
||||||
<script defer type="text/javascript" src="{{ $bundleJS.RelPermalink }}" integrity="{{ $bundleJS.Data.Integrity }}"></script>
|
{{ $bundleJS := $assets.Get "js" | resources.Concat "js/main.bundle.js" | resources.Minify | resources.Fingerprint "sha512" }}
|
||||||
|
<script defer type="text/javascript" src="{{ $bundleJS.RelPermalink }}" integrity="{{ $bundleJS.Data.Integrity }}"></script>
|
||||||
|
{{ end }}
|
||||||
{{/* Icons */}}
|
{{/* Icons */}}
|
||||||
{{ if templates.Exists "partials/favicons.html" }}
|
{{ if templates.Exists "partials/favicons.html" }}
|
||||||
{{ partialCached "favicons.html" .Site }}
|
{{ partialCached "favicons.html" .Site }}
|
||||||
|
|
Loading…
Reference in New Issue