mirror of https://github.com/onweru/compose.git

weru
30.04.2020 dfad1ec43b34f84ddcee2b94ea2641fe0d798a6c
1
2
3
4
5
6
7
8
9
10
11
{{- $lunrPath := "js/lunr.js" }}
{{- $lunr := resources.Get $lunrPath | resources.ExecuteAsTemplate $lunrPath . }}
 
{{- $searchPath := "js/search.js" }}
{{- $search := resources.Get $searchPath | resources.ExecuteAsTemplate $searchPath . }}
 
{{- $mainScriptPath := "js/index.js" }}
{{- $main := resources.Get $mainScriptPath | resources.ExecuteAsTemplate $mainScriptPath . }}
 
{{- $bundle := slice $lunr $search $main | resources.Concat "js/bundle.js" | resources.Minify | resources.Fingerprint "sha512" }}
<script src = '{{ $bundle.Permalink }}'></script>