add asset bundling, cache busting and fingerprinting to css and js
This commit is contained in:
parent
d54665763d
commit
6802a82d0d
9 changed files with 2590 additions and 5 deletions
2573
assets/css/fork-awesome.css
Normal file
2573
assets/css/fork-awesome.css
Normal file
File diff suppressed because it is too large
Load diff
2
assets/js/jquery-3.6.0.min.js
vendored
Normal file
2
assets/js/jquery-3.6.0.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
|
|
@ -7,11 +7,16 @@
|
||||||
{{- partial "footer.html" . -}}
|
{{- partial "footer.html" . -}}
|
||||||
|
|
||||||
<!-- We do need jQuery to be loaded before HugoScroll script -->
|
<!-- We do need jQuery to be loaded before HugoScroll script -->
|
||||||
<script type="text/javascript" src='{{ "js/jquery-3.6.0.min.js" | absURL }}'></script>
|
|
||||||
|
{{ $scriptJquery := resources.Get "js/jquery-3.6.0.min.js" }}
|
||||||
|
|
||||||
<!-- The main JavaScript files for HugoScroll -->
|
<!-- The main JavaScript files for HugoScroll -->
|
||||||
<script type="text/javascript" src='{{ "js/icons.js" | absURL }}'></script>
|
{{ $scriptIcons := resources.Get "js/icons.js" }}
|
||||||
<script type="text/javascript" src='{{ "js/index.js" |absURL }}'></script>
|
{{ $scriptIndex := resources.Get "js/index.js" }}
|
||||||
|
{{ $js := slice $scriptJquery $scriptIcons $scriptIndex | resources.Concat "js/script.js" | resources.Minify | resources.Fingerprint }}
|
||||||
|
|
||||||
|
<script type="text/javascript" src="{{ $js.Permalink }}" integrity="{{ $js.Data.Integrity }}" ></script>
|
||||||
|
|
||||||
<!-- A partial to be overwritten by the user.
|
<!-- A partial to be overwritten by the user.
|
||||||
Simply place a custom_body.html into
|
Simply place a custom_body.html into
|
||||||
your local /layouts/partials-directory -->
|
your local /layouts/partials-directory -->
|
||||||
|
|
|
||||||
|
|
@ -19,8 +19,13 @@
|
||||||
<meta name="MobileOptimized" content="320" />
|
<meta name="MobileOptimized" content="320" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||||
|
|
||||||
<link rel="stylesheet" href="{{ "css/screen.css" | absURL }}" />
|
{{ $stylesheetNormalize := resources.Get "css/normalize.css" }}
|
||||||
<link rel="stylesheet" href="{{ "css/fonts.css" | absURL }}" type="text/css" />
|
{{ $stylesheetFonts := resources.Get "css/fonts.css" }}
|
||||||
|
{{ $stylesheetScreen := resources.Get "css/screen.css" }}
|
||||||
|
{{ $stylesheet := slice $stylesheetNormalize $stylesheetFonts $stylesheetScreen | resources.Concat "css/style.css" | resources.Minify | resources.Fingerprint }}
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="{{ $stylesheet.Permalink }}" type="text/css" integrity="{{ $stylesheet.Data.Integrity }}" />
|
||||||
|
|
||||||
<link
|
<link
|
||||||
rel="stylesheet"
|
rel="stylesheet"
|
||||||
href="{{ "fork-awesome/css/fork-awesome.min.css" | absURL }}"
|
href="{{ "fork-awesome/css/fork-awesome.min.css" | absURL }}"
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue