Aaron Todd
04/30/2021, 1:46 PMLeft Nav |
-----------------------------------------------
module-1 v | // normal docs generated from sources
pkg1 |
pkg2 |
module-2 v |
pkg3 |
pkg4 |
...
custom v | // based on markdown file(s)
subpage1 |
subpage2 |
bonus points if we could link to these pages from API content
To clarify, I'm mostly wondering how to do this as a custom plugin, I wouldn't expect this to be supported as a general feature maintained by dokka developers (unless you think it's useful)Kamil Doległo
05/04/2021, 1:01 PMAaron Todd
05/04/2021, 1:06 PMKamil Doległo
05/04/2021, 1:13 PMPageTransformer
should be the easiest way to do so. In the invoke
method of the transformer you get the whole Page tree, so just add a node (or nodes) to it. I’ve just checked the NavigationDataProvider
and if the added nodes implement the ContentPage
interface, they should be parsed correctly with their child nodesAaron Todd
05/04/2021, 1:14 PMAaron Todd
05/04/2021, 1:16 PMincludes.from(markdownFile1, markdownFile2)
We may also want to link to parts of this supplemental documentation from the generated API docsKamil Doległo
05/04/2021, 1:18 PMDocumentableToPageTranslator
, I advise against it however, since transformers are easily composable and translators are not composable at allAaron Todd
05/04/2021, 1:19 PMKamil Doległo
05/04/2021, 1:21 PMallModulesPageTransformer
(in the AllModulesPagePlugin
plugin)Aaron Todd
05/04/2021, 1:23 PMKamil Doległo
05/04/2021, 1:25 PMMarcin Aman
05/04/2021, 4:29 PMMarcin Aman
05/04/2021, 4:37 PM