nicfab
1
In a post, I want to use the HTML tag like the following:
<h1 style="text-align: center;">Test</h1>
I see the content (in this case ‘Test’) in the TOC but clicking on it doesn’t work.
I use the PaperMod theme, and the toc.html is here: hugo-PaperMod/toc.html at master · adityatelange/hugo-PaperMod · GitHub
It works if I use the Markdown tag like # Test.
Is there anything I miss?
I’d stick with markdown:
### My Heading {style="text-align: center;"}
If you need to use HTML, I imagine your theme’s TOC partial needs an element id…
<h1 id="something" style="text-align: center;">Test</h1>
Please take this up with the theme author if you have further problems:
https://github.com/adityatelange/hugo-PaperMod/
nicfab
3
It works!
Thank you very much @jmooring