You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: build-test.gradle
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -13,7 +13,7 @@ buildscript {
13
13
}
14
14
15
15
dependencies {
16
-
classpath 'synapticloop:documentr:2.2.0'
16
+
classpath 'synapticloop:documentr:2.3.0'
17
17
}
18
18
}
19
19
@@ -36,7 +36,7 @@ group = 'synapticloop'
36
36
archivesBaseName ='documentr'
37
37
description ="""documentation (README) generator for projects in both markdown and asciidoc - this utilises the templar templating language - including generation of table of contents"""
Copy file name to clipboardExpand all lines: build.gradle
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -13,7 +13,7 @@ buildscript {
13
13
}
14
14
15
15
dependencies {
16
-
classpath 'synapticloop:documentr:2.2.0'
16
+
classpath 'synapticloop:documentr:2.3.0'
17
17
}
18
18
}
19
19
@@ -36,7 +36,7 @@ group = 'synapticloop'
36
36
archivesBaseName ='documentr'
37
37
description ="""documentation (README) generator for projects in both markdown and asciidoc - this utilises the templar templating language - including generation of table of contents"""
`documentr` can automatically generate the table fo contents for your documentation,
5
+
simply by entering the following line into you `documentr.json` file:
6
+
7
+
```
8
+
{ "type": "markup", "value": "\n\n# Table of Contents\n\n" },
9
+
10
+
{ "type": "toc", "value": "2" },
11
+
{ "type": "toclinks", "value": "true" },
12
+
```
13
+
By default, no title is generated - you will need to include one as simple markup.
14
+
15
+
This will generate both the table of contents and the links to all of the headers.
16
+
17
+
The `{ "type": "toc", "value": "2" }` line will generate links up to `h2` elements, by
18
+
default this will generate up to header level 6.
19
+
20
+
The `{ "type": "toclinks", "value": "true" },` line will generate links to he headers,
21
+
and will only work if `"type": "toc"` is also included.
22
+
23
+
> By default links are not generated. Unfortunately the developer of the markdown processor that is in use, does not distinguish block quote level elements correctly such that anything that looks like a header included in a blockquote will also be incorrectly identified as a header. This is why the links are not automatically generated by default.
0 commit comments