always generate appearance.js in js folder

depending on the basePath, the "appearance.js" was generated in an additional subfolder (i.E. /js/docs/appearance... instead of /js/appearance... ).
This commit is contained in:
Gottfried Mayer 2023-07-17 10:36:07 +02:00 committed by GitHub
parent ad79f8f19e
commit cfbfc2fbc1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -50,7 +50,7 @@
<link type="text/css" rel="stylesheet" href="{{ $bundleCSS.RelPermalink }}"
integrity="{{ $bundleCSS.Data.Integrity }}" />
{{ $jsAppearance := resources.Get "js/appearance.js" }}
{{ $jsAppearance = $jsAppearance | resources.ExecuteAsTemplate $jsAppearance.RelPermalink . | resources.Minify | resources.Fingerprint "sha512" }}
{{ $jsAppearance = $jsAppearance | resources.ExecuteAsTemplate "js/appearance.js" . | resources.Minify | resources.Fingerprint "sha512" }}
<script type="text/javascript" src="{{ $jsAppearance.RelPermalink }}"
integrity="{{ $jsAppearance.Data.Integrity }}"></script>
{{ if .Site.Params.enableSearch | default false }}