github Kotlin/dokka v2.2.0-Beta
2.2.0-Beta

pre-release15 hours ago

Dokka Gradle Plugin

Starting from Dokka 2.1.0, the new Dokka Gradle Plugin is enabled by default. The documentation on kotlinlang.org has been updated accordingly:

Dokka 2.2.0-Beta introduces multiple improvements and fixes:

Note: most of the following changes affect only the new Dokka Gradle Plugin, enabled by default since Dokka 2.1.0

Analysis improvements

Starting from Dokka 2.1.0, the K2 analysis is enabled by default. K2 analysis is now stable, enabled by default, and fully migrated to the new shared Analysis API. This includes the migration to the new KDoc resolution API within the Analysis API.

Dokka 2.2.0-Beta introduces multiple improvements and fixes:

Note: most of the following changes affect only Dokka's K2 analysis, enabled by default since Dokka 2.1.0

  • Allow actual declarations to automatically inherit their documentation from expect counterparts in multiplatform projects (#2493, #4245, #4351)
  • Link resolution improvements:
    • Support references to declarations with quoted names (#3356)
    • Support resolution of links to extensions with type parameters according to KEEP#385 (#3555)
    • Improve handling of ambiguous KDoc links according to KEEP#389 (#3451, #3179, #3632, #4327, #3604)
      • Note: those changes are currently available only under experimental org.jetbrains.dokka.analysis.enableExperimentalKDocResolution system property
  • K2/K1 compatibility improvements:
    • Fix Multiple pages associated with key (#4300)
    • Fix inconsistent constructor rendering for expect/actual annotation (#4055)
    • Fix missing abstract modifier for abstract interface method with redundant open modifier (#4144)
    • Fix working with intersected and overridden fake functions/properties (#3857)
    • Fix rendering of links in @see block (#3680)
    • Fix redundant ? on properties with a type of typealias to nullable type (#4337)
    • Fix the missing default parameter value for inherited (not overridden) members (#4320)
    • Fix duplicate source links for function overloads and properties (#4049, #4338)
    • Fix resolution of links in the second line of KDoc tags (#4332, KT-75215, KT-79783)
  • Improve DRI handling for varargs and properties (#3558, #4347)
  • Context parameters improvements:
    • Fix KDoc links to context parameters (#4389)
    • Support context parameters documentation via @param tag (#4065)
  • Java/Javadoc related improvements:
    • Use language-java class for <pre> and <code> tags generated from Java sources (#4346)
    • Add new Mark DocTag, TextStyle.Highlight and support for <mark> javadoc HTML tag (#4376)
    • Fix source links to accessors in the KotlinAsJava plugin (#4396)
    • Fix incorrect links to Javadoc's functions with type parameters (#3502)
    • Fix links to Java fields (#4360)
    • Fix documentation on extension properties is not propagated to the generated extension getters (#3752)
    • Fix generated getter for property in kotlin-as-java doesn't inherit KDoc description (#3369)

Kotlin playground runnable samples extracted into a separate plugin

Starting with Dokka 2.2.0-Beta, Kotlin Playground–based rendering of @sample KDoc references is disabled by default. Samples are now rendered as non-runnable code blocks.

Support for interactive, runnable samples has been extracted into a separate plugin with configurable options, including custom Playground scripts and server URLs. See the plugin README.md for setup instructions.

Other changes and bugfixes

  • Fix unnecessary logging for unresolved links in module documentation (#4413)
  • Fix CLI runner to force use of the latest stdlib (#4324)
  • Use the shadowed stdlib in the Dokka Maven Plugin (#4229)

Feedback

We would appreciate your feedback!

Don't miss a new dokka release

NewReleases is sending notifications on new releases.