Use js generation from hugo instead of webpack

This commit is contained in:
Djordje Atlialp 2019-02-22 15:22:10 +01:00
parent b2d7367605
commit 14768f7c13
No known key found for this signature in database
GPG key ID: 94FF806E6BF61DD3

View file

@ -23,7 +23,15 @@
</div>
</footer>
<script src="/assets/main.js"></script>
<!-- JavaScript -->
{{ $main := resources.Get "js/main.js" }}
{{ $menu := resources.Get "js/menu.js" }}
{{ $prism := resources.Get "js/prism.js" }}
{{ $theme := resources.Get "js/theme.js" }}
{{ $js := slice $main $menu $prism $theme | resources.Concat "js/bundle.js" }}
{{ $secureJS := $js | resources.Fingerprint "sha512" }}
<script type="text/javascript" src="{{ $secureJS.Permalink }}" integrity="{{ $secureJS.Data.Integrity }}"></script>
{{- if .Site.GoogleAnalytics }}
<script>