2020-02-27 12:17:21 +00:00
|
|
|
{{ if default true .Site.Params.GeekdocSearch }}
|
|
|
|
{{ .Scratch.Set "geekdocSearchConfig" .Site.Params.GeekdocSearchConfig }}
|
|
|
|
<!-- Remove after https://github.com/gohugoio/hugo/issues/6331 -->
|
|
|
|
{{ $searchJSFile := printf "js/%s.search.js" .Language.Lang }}
|
|
|
|
{{ $searchJS := resources.Get "js/search.js" | resources.ExecuteAsTemplate $searchJSFile . | resources.Minify }}
|
|
|
|
<script defer src="{{ $searchJS.RelPermalink }}"></script>
|
|
|
|
{{ end }}
|
|
|
|
|
|
|
|
{{ if default true .Site.Params.GeekdocAnchorCopy }}
|
2020-06-01 13:59:02 +00:00
|
|
|
<script defer src="{{ "js/clipboard.min.js" | relURL }}"></script>
|
2020-02-27 12:17:21 +00:00
|
|
|
<script>
|
2020-06-01 13:59:02 +00:00
|
|
|
document.addEventListener("DOMContentLoaded", function(event) {
|
|
|
|
var clipboard = new ClipboardJS('.clip');
|
|
|
|
});
|
2020-02-27 12:17:21 +00:00
|
|
|
</script>
|
|
|
|
{{ end }}
|