Here is an example Table of Contents. Each entry becomes a link to the appropriate section.
Note that any text added after the last section appears to be part of the last section.
Note that level 1 headings are not included in the table of contents. The table of contents lists headings at level 2 and below. Headings must be numbered (using the # tag) to show up in the table of contents.
The example below was generated with the following text:
<toc>
== # Test ==
: Here we will test the table of contents.
: With indented text
== A Heading Hidden from the TOC ==
: This is some more indented text
: This is some more indented text
=== # Test (again) ===
: This is some indented text
: This is some indented text
: This is some indented text
== # SandBox SampleUndefinedPage ==
: This is some more indented text
: This is some more indented text
: This is some more indented ext
: This is some more indented text
=== # I am ''italics'' and '''bold''' ===
This is yet even more text
This is yet even more text
This is yet even more text
This is yet even more text
==== # I am <b>bold</b> and <i>italics</i> ====
another Paragraph
another Paragraph
another Paragraph
=== # I am a [http://example.com bracketed link]. ===
some more crap
some more crap
some more crap
some more crap
==== # An inline image https://www.usemod.org/wiki.gif ====
With Text added.
-
- 1. Test
-
- 2. SandBox SampleUndefinedPage
-
-
- 2.1. I am italics and bold
-
-
- 2.1.1. I am bold and italics
-
2.2. I am a [bracketed link].
-
-
- 2.2.1. An inline image

-
1. Test
- This is some indented text
- This is some indented text
- This is some indented text
A Heading Hidden from the TOC
- This is some more indented text
- This is some more indented text
2. SandBox SampleUndefinedPage?
- This is some more indented text
- This is some more indented text
- This is some more indented ext
- This is some more indented text
2.1. I am italics and bold
This is yet even more text
This is yet even more text
This is yet even more text
This is yet even more text
2.1.1. I am bold and italics
another Paragraph
another Paragraph
another Paragraph
some more crap
some more crap
some more crap
some more crap
2.2.1. An inline image 
With Text added.