On-page navigation
When you have many sections on a page, it’s good to provide a table of contents for a better overview.
To show a table of contents for the current page,
use the contents
directive with the :local:
option.
You must provide a title for the directive to render.
By default, headings included after this directive are links back to the contents section
(as you can see on this page).
If you want to turn off this behavior, use :backlinks: none
.
Section 1
Some random text.
Subsection 1.1
More random text
Subsection 1.2
More random text
Section 2
Some random text.
Subsection 2.1
More random text
Subsection 2.2
More random text