dokka alternatives and similar libraries
Based on the "Tools" category.
Alternatively, view dokka alternatives based on common mentions on social networks and blogs.
-
kotlin-android-template
Android + Kotlin + Github Actions + ktlint + Detekt + Gradle Kotlin DSL + buildSrc = ❤️ -
jtransc
DISCONTINUED. Bytecode to source converting Java & Kotlin code into JavaScript, C++, D, C#, PHP, AS3, Dart and Haxe and run it everywhere. Also use JVM code in your favourite language as a library. -
Ostara
Ostara is a cross-platform desktop app for managing and monitoring Spring Boot applications using the Actuator API, providing comprehensive insights and effortless control. -
MpApt
DISCONTINUED. (Deprecated) :wrench: Kotlin Native/JS/JVM Annotation Processor library for Kotlin compiler plugins -
ktfmt-gradle
A Gradle plugin to apply ktfmt to your builds, and reformat you Kotlin source code like a glimpse 🧹🐘 -
ComposeRecyclerView
Seamlessly integrate Jetpack Compose composables in RecyclerView with ComposeRecyclerView🔥. This library enhances performance⚡, tackles LazyList issues🔨, and offers built-in drag-and-drop👨🏽💻 support for dynamic UIs. -
LiveStream-Kt (Android) 📱
DISCONTINUED. LiveStream is a simple class which makes communication easy among different modules of your application. -
ARFaceDetection
AR-based library for Android which is capable of detecting faces and overlaying images above the user’s head -
Kotlin Bootstrap
This set of libraries is designed to help developers accomplish various tasks easier and faster -
GradleMavenPush
Helper to upload Gradle Android Artifacts, Gradle Java Artifacts and Gradle Kotlin Artifacts to Maven repositories (JCenter, Maven Central, Corporate staging/snapshot servers and local Maven repositories). -
EasyDokkaPlugin
Gradle Script plugin to generate documentation by Dokka documentation engine in Javadoc or other formats for Java, Kotlin, Android and non-Android projects. It's very easy, you don't need to add to dependencies section additional classpath or think about compatibility issues, you don't need additional repositories also. -
buildSrcVersions
Better Gradle dependencies management inside the IDE. Search for available updates.
InfluxDB - Purpose built for real-time analytics at any scale.
Do you think we are missing an alternative of dokka or a related project?
Popular Comparisons
README
Dokka
Dokka is a documentation engine for Kotlin, performing the same function as javadoc for Java. Just like Kotlin itself, Dokka fully supports mixed-language Java/Kotlin projects. It understands standard Javadoc comments in Java files and KDoc comments in Kotlin files, and can generate documentation in multiple formats including standard Javadoc, HTML and Markdown.
Using Dokka
Full documentation is available at https://kotlin.github.io/dokka/1.7.10/
Using the Gradle plugin
Note: If you are upgrading from 0.10.x to a current release of Dokka, please have a look at our [migration guide](runners/gradle-plugin/MIGRATION.md)
The preferred way is to use plugins
block.
build.gradle.kts:
plugins {
id("org.jetbrains.dokka") version "1.7.10"
}
repositories {
mavenCentral()
}
The plugin adds dokkaHtml
, dokkaJavadoc
, dokkaGfm
and dokkaJekyll
tasks to the project.
Applying plugins
Dokka plugin creates Gradle configuration for each output format in the form of dokka${format}Plugin
:
dependencies {
dokkaHtmlPlugin("org.jetbrains.dokka:kotlin-as-java-plugin:1.7.10")
}
You can also create a custom Dokka task and add plugins directly inside:
val customDokkaTask by creating(DokkaTask::class) {
dependencies {
plugins("org.jetbrains.dokka:kotlin-as-java-plugin:1.7.10")
}
}
Please note that dokkaJavadoc
task will properly document only single jvm
source set
To generate the documentation, use the appropriate dokka${format}
Gradle task:
./gradlew dokkaHtml
Please see the Dokka Gradle example project for an example.
We encourage users to create their own plugins and share them with the community on [official plugins list](docs/src/doc/docs/community/plugins-list.md).
Android
Make sure you apply Dokka after com.android.library
and kotlin-android
.
buildscript {
dependencies {
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:${kotlin_version}")
classpath("org.jetbrains.dokka:dokka-gradle-plugin:${dokka_version}")
}
}
repositories {
mavenCentral()
}
apply(plugin= "com.android.library")
apply(plugin= "kotlin-android")
apply(plugin= "org.jetbrains.dokka")
dokkaHtml.configure {
dokkaSourceSets {
named("main") {
noAndroidSdkLink.set(false)
}
}
}
Multi-module projects
For documenting Gradle multi-module projects, you can use dokka${format}Multimodule
tasks.
tasks.dokkaHtmlMultiModule.configure {
outputDirectory.set(buildDir.resolve("dokkaCustomMultiModuleOutput"))
}
DokkaMultiModule
depends on all Dokka tasks in the subprojects, runs them, and creates a toplevel page
with links to all generated (sub)documentations
Using the Maven plugin
The Maven plugin does not support multi-platform projects.
Documentation is by default generated in target/dokka
.
The following goals are provided by the plugin:
dokka:dokka
- generate HTML documentation in Dokka format (showing declarations in Kotlin syntax)dokka:javadoc
- generate HTML documentation in Javadoc format (showing declarations in Java syntax)dokka:javadocJar
- generate a .jar file with Javadoc format documentation
Applying plugins
You can add plugins inside the dokkaPlugins
block:
<plugin>
<groupId>org.jetbrains.dokka</groupId>
<artifactId>dokka-maven-plugin</artifactId>
<version>${dokka.version}</version>
<executions>
<execution>
<phase>pre-site</phase>
<goals>
<goal>dokka</goal>
</goals>
</execution>
</executions>
<configuration>
<dokkaPlugins>
<plugin>
<groupId>org.jetbrains.dokka</groupId>
<artifactId>kotlin-as-java-plugin</artifactId>
<version>${dokka.version}</version>
</plugin>
</dokkaPlugins>
</configuration>
</plugin>
Please see the Dokka Maven example project for an example.
Using the Command Line
To run Dokka from the command line, download the Dokka CLI runner. To generate documentation, run the following command:
java -jar dokka-cli.jar <arguments>
You can also use a JSON file with dokka configuration:
java -jar <dokka_cli.jar> <path_to_config.json>
Output formats
Dokka documents Java classes as seen in Kotlin by default, with javadoc format being the only exception.
html
- HTML format used by defaultjavadoc
- looks like JDK's Javadoc, Kotlin classes are translated to Javagfm
- GitHub flavored markdownjekyll
- Jekyll compatible markdown
If you want to generate the documentation as seen from Java perspective, you can add the kotlin-as-java
plugin
to the Dokka plugins classpath, eg. in Gradle:
dependencies{
implementation("...")
dokkaGfmPlugin("org.jetbrains.dokka:kotlin-as-java-plugin:${dokka-version}")
}
FAQ
If you encounter any problems, please see the FAQ.