1
0

make headings link to themselves

This commit is contained in:
Simon Michael
2023-11-30 14:19:37 -10:00
parent 765ee49157
commit ed2b2fd2a1
4 changed files with 17 additions and 3 deletions

7
headings.lua Normal file
View File

@@ -0,0 +1,7 @@
-- Make all headings (except the page h1 added by page.tmpl)
-- clickable links to themselves, for easy bookmarking/linking.
function Header(el)
el.content = pandoc.Link(el.content, '#' .. el.identifier)
return el
end