{{- with $.Page.Scratch.Get "sidenoteCounter" -}}
{{- $.Page.Scratch.Set "sidenoteCounter" (add . 1) -}}
{{- else -}}
{{- $.Page.Scratch.Set "sidenoteCounter" 1 -}}
{{- end -}}
{{- $sidenoteDomIdSuffix := $.Page.Scratch.Get "sidenoteCounter" -}}
({{ $sidenoteDomIdSuffix }}){{ .Inner | markdownify }}