dokka
dokka copied to clipboard
How can I document root level package?
Question
How can I document root level package? e.g. this component
package doesn't contain any classes, but only other packages?
I've defined in packages.md
with the following:
# Package com.ninegag.android.app.component
`component` package is deprecated, don't add anything new to it
The dokka generated doesn't add this description to the root level of the package. If I would like to tell people that the .component
package is deprecated, what is the best way to do so? Thank you
Screenshots If applicable, add screenshots to help explain your problem
Installation
- Operating system: macOS/Windows/Linux
- Build tool: Gradle v6.8.0/Maven/Cli/3rd party plugin
- Dokka version: 1.4.30
Additional context Add any other context about the problem here
Hi! You seem to be on the right path, but it's unclear whether you've added packages.md
to includes
configuration param.
If you look at kotlinx.coroutines, they have configured Dokka in the following way:
tasks.withType(DokkaTaskPartial::class).configureEach {
...
dokkaSourceSets.configureEach {
...
includes.from("README.md")
...
}
}
And in the root of a module they have a README.md file with package descriptions, just like in the example you've provided:
# Package kotlinx.coroutines
General-purpose coroutine builders, contexts, and helper functions.
Which is then parsed by Dokka and you can see this description in generated documentation:
Hopefully that's what you're missing and you're able to configure it. If not, let us know
Closing the issue as stale, hopefully the issue has been resolved. Let us know if the question is still relevant