1
0
mirror of https://github.com/Wonderfall/hugo-WonderMod.git synced 2025-01-11 10:40:58 +01:00
hugo-theme-wondermod/layouts/partials/anchored_headings.html
2021-03-30 18:26:43 +05:30

3 lines
212 B
HTML

{{- /* formats .Content headings by adding an anchor */ -}}
{{ . | replaceRE "(<h[1-6] id=\"([^\"]+)\".+)(</h[1-6]+>)" "${1}<a hidden class=\"anchor\" aria-hidden=\"true\" href=\"#${2}\">#</a>${3}" | safeHTML }}