diff options
author | Lars Wirzenius <liw@liw.fi> | 2022-11-09 15:56:55 +0200 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2022-11-09 15:56:55 +0200 |
commit | 8f17b2a721d2369691ff2e3d4950a436aa9533ab (patch) | |
tree | 1041e81264145d66a5b168b82c546234b36d80cc /riki.md | |
parent | 249323a6009a35dd2e77be794ed45b5f1cf4263f (diff) | |
download | riki-8f17b2a721d2369691ff2e3d4950a436aa9533ab.tar.gz |
feat: implement rudimentary table of contents, without links
The links will be added later.
Sponsored-by: author
Diffstat (limited to 'riki.md')
-rw-r--r-- | riki.md | 20 |
1 files changed, 20 insertions, 0 deletions
@@ -677,6 +677,26 @@ goodbye | cruel world """]] ~~~ +### `toc` + +_Requirement: the `toc` directive creates a table of contents._ + +~~~scenario +given an installed riki +given file site/index.mdwn from toc +when I run riki build site output +when I run cat output/index.html +then file output/index.html contains "<li>Introduction</li>" +then file output/index.html contains "<li>Acknowledgements</li>" +~~~ + +~~~{#toc .file .markdown} +[[!toc]] + +# Introduction +## Acknowledgements +~~~ + ## Source file tree ### Listing source files |