Welcome to mirror list, hosted at ThFree Co, Russian Federation.

anchor.html « partials « layouts - github.com/wlh320/hugo-theme-hulga.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 313277da8194eb6b18c7ee45b19672d1071eae63 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
{{- if .Site.Params.noCDN -}}
<script src={{ "js/anchor.min.js" | absURL }}></script>
{{- else -}}
<script src="https://cdn.jsdelivr.net/npm/anchor-js@4.3.0/anchor.min.js"></script>
{{- end -}}
<script>
  anchors.options = {
    placement: 'left',
    // visible: 'always',
    icon: '#'
  };
  anchors.add('.content h1, .content h2, .content h3');
</script>