{"id":23306997,"url":"https://github.com/jolanrensen/kodex","last_synced_at":"2025-08-22T10:32:02.331Z","repository":{"id":65765276,"uuid":"583384731","full_name":"Jolanrensen/KoDEx","owner":"Jolanrensen","description":"/** KoDEx */: Kotlin Documentation Extensions. KDoc preprocessor Gradle plugin and IDEA plugin (Beta).","archived":false,"fork":false,"pushed_at":"2024-12-17T13:05:24.000Z","size":1024,"stargazers_count":19,"open_issues_count":12,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-12-17T13:34:28.826Z","etag":null,"topics":["documentation","documentation-generator","documentation-tool","gradle","gradle-plugin","java","javadoc","javadocs","kdoc","kdocs","kotlin","library","library-management","plugin","plugins","preprocessor","preprocessors"],"latest_commit_sha":null,"homepage":"","language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Jolanrensen.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-12-29T16:09:24.000Z","updated_at":"2024-12-17T13:01:39.000Z","dependencies_parsed_at":"2023-02-20T23:46:04.767Z","dependency_job_id":"329c905c-38b1-48b5-8aec-b7674477ff2d","html_url":"https://github.com/Jolanrensen/KoDEx","commit_stats":null,"previous_names":["jolanrensen/kodex"],"tags_count":52,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jolanrensen%2FKoDEx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jolanrensen%2FKoDEx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jolanrensen%2FKoDEx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jolanrensen%2FKoDEx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Jolanrensen","download_url":"https://codeload.github.com/Jolanrensen/KoDEx/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230583116,"owners_count":18248727,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["documentation","documentation-generator","documentation-tool","gradle","gradle-plugin","java","javadoc","javadocs","kdoc","kdocs","kotlin","library","library-management","plugin","plugins","preprocessor","preprocessors"],"created_at":"2024-12-20T12:20:03.182Z","updated_at":"2024-12-20T12:20:03.865Z","avatar_url":"https://github.com/Jolanrensen.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cimg src=\"KoDExColored.svg\" align=\"right\" width=\"75\" height=\"75\"\u003e\n\n# `/** KoDEx */`: Kotlin Documentation Extensions\n[![Maven metadata URL](https://img.shields.io/maven-metadata/v?label=Gradle%20Plugin\u0026metadataUrl=https%3A%2F%2Fplugins.gradle.org%2Fm2%2Fnl%2Fjolanrensen%2FdocProcessor%2Fnl.jolanrensen.docProcessor.gradle.plugin%2Fmaven-metadata.xml)](https://plugins.gradle.org/plugin/nl.jolanrensen.docProcessor)\n\nKDoc Preprocessor Gradle Plugin and IDEA plugin (Beta)\n\nThis Gradle plugin allows you to adapt your KDoc comments with custom preprocessors and obtain modified\nsources.\n\nThese preprocessors can add custom tags to your KDoc comments or change the entirety of the\ncomment.\nThis is not a Dokka plugin, meaning you can actually get a `sources.jar` file with the modified comments instead of just\nhaving the comments modified in a `javadoc.jar` or a Dokka HTML website.\n\nNote: `{@inline tags}` work in KDoc comments too! Plus, `{@tags {@inside tags}}` are supported too.\n\n## Example\n\n### What you write:\n\n\u003cdiv style=\"width: 100%;\"\u003e\n  \u003cimg src=\"whatYouWrite.svg\" style=\"width: 100%;\" alt=\"Click to see the source\"\u003e\n\u003c/div\u003e\n\n### What you get:\n\n\u003cdiv style=\"width: 100%;\"\u003e\n  \u003cimg src=\"whatYouGet.svg\" style=\"width: 100%;\" alt=\"Click to see the source\"\u003e\n\u003c/div\u003e\n\n## Used By\n\nThis plugin is used by [Kotlin DataFrame](https://github.com/Kotlin/dataframe), to make it possible\nto document and update the wide range of function overloads present in the library due to its DSL-like nature.\n\nLet me know if you're using it in your project too!\n\n## Preprocessors\n\nPreprocessors are run one at a time, in order, on all KDoc / JavaDoc comments in the sources.\nIf a preprocessor is a tag processor, it will process only its own tags in the following order:\n\n- Inline tags\n    - depth-first\n    - top-to-bottom\n    - left-to-right\n- Block tags\n    - top-to-bottom\n\nIncluded preprocessors are:\n\n| Description                                                                                                                                                                                                                                                                                    | Name                            |\n|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------|\n| `@include` tag to include other documentation into your KDoc / JavaDoc.\u003cbr/\u003eUsed like `@include [Reference.To.Element]`.                                                                                                                                                                       | `INCLUDE_DOC_PROCESSOR`         |\n| `@includeFile` tag to include the entire content of a file into your KDoc / JavaDoc.\u003cbr/\u003eUsed like `@includeFile (./path/to/file)`.                                                                                                                                                            | `INCLUDE_FILE_DOC_PROCESSOR`    |\n| `@set` / `@get` (or `$`) tags to define and retrieve variables within a KDoc / JavaDoc. Powerful in combination with `@include`.\u003cbr/\u003eUsed like `@set KEY some content`, `@get KEY some default`.\u003cbr/\u003eShortcuts for `{@get .}` are `$KEY`, `$KEY=default`, `${KEY}`, and `${KEY=some default}`. | `ARG_DOC_PROCESSOR`             |\n| `@comment` tag to comment out parts of your modified KDoc / JavaDoc.\u003cbr/\u003eUsed like `@comment Some comment text`.                                                                                                                                                                               | `COMMENT_DOC_PROCESSOR`         |\n| `@sample` / `@sampleNoComments` tags to include code samples into your KDoc / JavaDoc.\u003cbr/\u003eUsed like `@sample [Reference.To.Element]`.\u003cbr/\u003eIf present, only code in between `// SampleStart` and `// SampleEnd` is taken. `@sampleNoComments` excludes KDoc / JavaDoc from the sample.         | `SAMPLE_DOC_PROCESSOR`          |\n| `@exportAsHtmlStart` / `@exportAsHtmlEnd` to mark a range of KDoc for the `@ExportAsHtml` annotation.                                                                                                                                                                                          | `EXPORT_AS_HTML_DOC_PROCESSOR`  |\n| A processor that removes all escape characters (\"\\\\\") from your KDoc / JavaDoc comments.                                                                                                                                                                                                       | `REMOVE_ESCAPE_CHARS_PROCESSOR` |\n| A processor that removes all KDoc / JavaDoc comments.                                                                                                                                                                                                                                          | `NO_DOC_PROCESSOR`              |\n| A processor that adds a `/** TODO */` comment wherever there is no KDoc / JavaDoc comment.                                                                                                                                                                                                     | `TODO_DOC_PROCESSOR`            |\n\nOf course, you can also try to make your own preprocessor (see [Custom Processors](#custom-processors)).\nFor instance, you could make a processor that makes all KDoc / JavaDoc comments uppercase,\na tag processor that automatically inserts URLs to your website, or simply a processor that produces\nerrors or warnings for incorrect doc usage.\n\nThe sky is the limit :).\n\n## `@ExcludeFromSources` annotation\n\nIf you want to exclude any annotatable element from the `sources.jar`. \nCreate an annotation class named exactly \"`ExcludeFromSources`\" \n(you can copy the code from [here](./doc-processor-common/src/main/kotlin/nl/jolanrensen/docProcessor/ExcludeFromSources.kt))\nand annotate the elements you want to exclude with it.\nThis is especially useful for \"temporary\" documentation interfaces, only there\nto provide documentation for other elements.\n\n\n## `@ExportAsHtml` annotation\n\nTo export a KDoc comment as HTML, you can use the `@ExportAsHtml` annotation.\nCreate an annotation class named exactly \"`ExportAsHtml`\" and add the arguments `theme: Boolean` and \n`stripReferences: Boolean` (default both to `true`)\n(you can copy the code from [here](./doc-processor-common/src/main/kotlin/nl/jolanrensen/docProcessor/ExportAsHtml.kt)).\nThen, add the annotation to the element you want to export as HTML.\n\nInside the KDoc comment, you can mark a range of text to be exported as HTML by using the optional `@exportAsHtmlStart` \nand `@exportAsHtmlEnd` tags.\n\nIn the Gradle task the HTML will be generated in the folder specified in the `exportAsHtml` block of the\n`ProcessDocTask` (see below). In the IntelliJ plugin, a temporary file will be created that you can open in the\nbrowser by clicking on link at the bottom of the rendered KDoc.\n\n## How to get it\n\n### From Gradle Plugins\n\nIn your project's `settings.gradle.kts` or `build.gradle` add:\n\n```kts\npluginManagement {\n    repositories {\n        ..\n        gradlePluginPortal()\n    }\n}\n```\n\nIn `build.gradle.kts` or `build.gradle` add `id(\"nl.jolanrensen.docProcessor\") version \"{ VERSION }\"`\nto `plugins { .. }`.\n\n### From sources\n\nClone the project and run `./gradlew publishToMavenLocal` in the source folder.\n\nIn your project's `settings.gradle.kts` or `settings.gradle` add:\n\n```kts\npluginManagement {\n    repositories {\n        ..\n        mavenLocal()\n    }\n}\n```\n\nIn `build.gradle.kts` or `build.gradle` add `id(\"nl.jolanrensen.docProcessor\") version \"{ VERSION }\"`\nto `plugins { .. }`.\n\n## How to use\n\nSay you want to create a task that will run when you're making a sources Jar such that the modified files appear in the\nJar:\n\n`build.gradle.kts`:\n\n```kts\nimport nl.jolanrensen.docProcessor.gradle.*\nimport nl.jolanrensen.docProcessor.defaultProcessors.*\nimport org.gradle.jvm.tasks.Jar\n\n..\n\nplugins {\n    id(\"nl.jolanrensen.docProcessor\") version \"{ VERSION }\"\n    ..\n}\n\n..\n\n// Backup the kotlin source files location\nval kotlinMainSources = kotlin.sourceSets.main.get().kotlin.sourceDirectories\n\n// Create the processing task and point it to the right sources. \n// This can also be the test sources for instance.\nval processKdocMain by creatingProcessDocTask(sources = kotlinMainSources) {\n\n    // Optional. The target folder of the processed files. By default ${project.buildDir}/docProcessor/${taskName}.\n    target = file(..)\n\n    // The processors you want to use in this task.\n    // The recommended order of default processors is as follows:\n    processors = listOf(\n        INCLUDE_DOC_PROCESSOR, // The @include processor\n        INCLUDE_FILE_DOC_PROCESSOR, // The @includeFile processor\n        ARG_DOC_PROCESSOR, // The @set and @get / $ processor\n        COMMENT_DOC_PROCESSOR, // The @comment processor\n        SAMPLE_DOC_PROCESSOR, // The @sample and @sampleNoComments processor\n        EXPORT_AS_HTML_DOC_PROCESSOR, // The @exportAsHtmlStart and @exportAsHtmlEnd tags for @ExportAsHtml\n        REMOVE_ESCAPE_CHARS_PROCESSOR, // The processor that removes escape characters\n\n        \"com.example.plugin.ExampleDocProcessor\", // A custom processor if you have one, see below\n    )\n\n    // Optional. Send specific arguments to processors.\n    arguments += ARG_DOC_PROCESSOR_LOG_NOT_FOUND to false\n\n    // Optional dependencies for this task. These dependencies can introduce custom processors.\n    dependencies {\n        plugin(\"com.example:plugin:SOME_VERSION\")\n    }\n\n    // Optional, defines where @ExportAsHtml will put the generated HTML files. By default ${project.buildDir}/docProcessor/${taskName}/htmlExports.\n    exportAsHtml {\n      dir = file(\"../docs/StardustDocs/snippets\")\n    }\n}\n\n// Modify all Jar tasks such that before running the Kotlin sources are set to \n// the target of processKdocMain and they are returned back to normal afterwards.\ntasks.withType\u003cJar\u003e {\n    dependsOn(processKdocMain)\n    outputs.upToDateWhen { false }\n\n    doFirst {\n        kotlin {\n            sourceSets {\n                main {\n                    kotlin.setSrcDirs(processKdocMain.targets)\n                }\n            }\n        }\n    }\n\n    doLast {\n        kotlin {\n            sourceSets {\n                main {\n                    kotlin.setSrcDirs(kotlinMainSources)\n                }\n            }\n        }\n    }\n}\n\n..\n\n// As a bonus, this will update dokka to use the processed files as sources as well.\ntasks.withType\u003corg.jetbrains.dokka.gradle.AbstractDokkaLeafTask\u003e {\n    dokkaSourceSets {\n        all {\n            sourceRoot(processKdocMain.target.get())\n        }\n    }\n}\n```\n\n`build.gradle`:\n\n```groovy\nimport nl.jolanrensen.docProcessor.gradle.*\nimport nl.jolanrensen.docProcessor.defaultProcessors.*\nimport org.gradle.jvm.tasks.Jar\n\n..\n\nplugins {\n    id \"nl.jolanrensen.docProcessor\" version \"{ VERSION }\"\n            ..\n}\n\n        ..\n\n// Backup the kotlin source files location\ndef kotlinMainSources = kotlin.sourceSets.main.kotlin.sourceDirectories\n\n// Create the processing task and point it to the right sources. \n// This can also be the test sources for instance.\ndef processKdocMain = tasks.register('processKdocMain', ProcessDocTask) {\n\n    // Optional. The target folder of the processed files. By default ${project.buildDir}/docProcessor/${taskName}.\n    target file(..)\n\n    // The processors you want to use in this task.\n    // The recommended order of default processors is as follows:\n    processors(\n            IncludeDocProcessorKt.INCLUDE_DOC_PROCESSOR, // The @include processor\n            IncludeFileDocProcessorKt.INCLUDE_FILE_DOC_PROCESSOR, // The @includeFile processor\n            ArgDocProcessorKt.ARG_DOC_PROCESSOR, // The @set and @get / $ processor\n            CommentDocProcessorKt.COMMENT_DOC_PROCESSOR, // The @comment processor\n            SampleDocProcessorKt.SAMPLE_DOC_PROCESSOR, // The @sample and @sampleNoComments processor\n            ExportAsHtmlDocProcessorKt.EXPORT_AS_HTML_DOC_PROCESSOR, // The @exportAsHtmlStart and @exportAsHtmlEnd tags for @ExportAsHtml\n            RemoveEscapeCharsProcessorKt.REMOVE_ESCAPE_CHARS_PROCESSOR, // The processor that removes escape characters\n\n            \"com.example.plugin.ExampleDocProcessor\", // A custom processor if you have one, see below\n    )\n\n    // Optional. Send specific arguments to processors.\n    arguments[IncludeArgDocProcessorKt.ARG_DOC_PROCESSOR] = false\n\n    // Optional dependencies for this task. These dependencies can introduce custom processors.\n    dependencies {\n        plugin \"com.example:plugin:SOME_VERSION\"\n    }\n\n    // Optional, defines where @ExportAsHtml will put the generated HTML files. By default ${project.buildDir}/docProcessor/${taskName}/htmlExports.\n    exportAsHtmlDir = file(\"../docs/StardustDocs/snippets\")\n    \n}.get()\n\n// Modify all Jar tasks such that before running the Kotlin sources are set to \n// the target of processKdocMain and they are returned back to normal afterwards.\ntasks.withType(Jar).configureEach {\n    dependsOn(processKdocMain)\n    outputs.upToDateWhen { false }\n\n    doFirst {\n        kotlin {\n            sourceSets {\n                main {\n                    kotlin.srcDirs = processKdocMain.targets\n                }\n            }\n        }\n    }\n\n    doLast {\n        kotlin {\n            sourceSets {\n                main {\n                    kotlin.srcDirs = kotlinMainSources\n                }\n            }\n        }\n    }\n}\n\n        ..\n\n// As a bonus, this will update dokka to use the processed files as sources as well.\n        tasks.withType(org.jetbrains.dokka.gradle.AbstractDokkaLeafTask).configureEach {\n            dokkaSourceSets.with {\n                configureEach {\n                    sourceRoot(processKdocMain.target.get())\n                }\n            }\n        }\n```\n\n### Recommended order of default processors\n\nWhile you can use the processors in any order and leave out some or include others, the recommended order is as follows:\n\n- `INCLUDE_DOC_PROCESSOR`: The `@include` processor\n- `INCLUDE_FILE_DOC_PROCESSOR`: The `@includeFile` processor\n- `ARG_DOC_PROCESSOR`: The `@set` and `@get` / `$` processor. This runs `@set` first and then `@get` / `$`.\n- `COMMENT_DOC_PROCESSOR`: The `@comment` processor\n- `SAMPLE_DOC_PROCESSOR`: The `@sample` and `@sampleNoComments` processor\n- `EXPORT_AS_HTML_DOC_PROCESSOR`: The `@exportAsHtmlStart` and `@exportAsHtmlEnd` tags for `@ExportAsHtml`\n- `REMOVE_ESCAPE_CHARS_PROCESSOR`: The processor that removes escape characters\n\nThis order ensures that `@set`/`@get` are processed after `@include` and `@includeFile` such that any arguments\nthat appear by them are available for the `@set`/`@get` processor.\nThe `@comment` processor is recommended to be after `@set`/`@get` too, as it can be used as a line break for\ntag blocks. `@sample` and `@sampleNoComments` are recommended to be last of the tag processors, as processing of inline\ntags inside comments of `@sample` might not be desired. Finally, the `REMOVE_ESCAPE_CHARS_PROCESSOR` is recommended to\nbe last to clean up any escape characters that might have been introduced by the user to evade some parts of the docs\nfrom being processed.\n\n## Technicalities\n\nRegarding block-tags KDocs and JavaDocs are structured in a tree-like structure and are thus also parsed and processed\nlike that.\nFor example, the following KDoc:\n\n```kotlin\n/**\n * Some extra text\n * @a [Test2]\n * Hi there!\n * @b source someFun\n * Some more text. {@c\n * @d [Test1] (\n * }\n * @e)\n */\n```\n\nwill be split up in blocks as follows:\n\n```\n[\n  \"\\nSome extra text\",\n  \"@a [Test2]\\nHi there!\",\n  \"@b source someFun\\nSome more text. (\\n{@c [Test1] (\\n}\",\n  \"@e)\\n\",\n]\n```\n\nThis is also how tag processors receive their block-data (note that any newlines after the `@tag`\nare also included as part of the tag data).\n\nMost tag processors only require a tiny number of arguments. They can decide what to do when they receive more arguments\nby the user.\nMost tag processors, like `@include`, `@sample`, and `@includeFile` all have systems in place that\nwill preserve the content after the tag.\nTake this into account when writing your own processors.\n\nTo avoid any confusion, it's usually easier to stick to `{@inline tags}` as then it's clear which part of the doc\nbelongs to the tag and what does not. Inline tags are processed before block tags per processor.\n\nTake extra care when using tags that can introduce new tags, such as `@include`, as this will cause the structure\nof the doc to change mid-processing. Very powerful, but also potentially dangerous.\nIf something weird happens, try to disable some processors to understand what's happening.\n\n## How it works\n\n- The sources provided to the plugin are read and analysed by\n  [Dokka's default SourceToDocumentableTranslators](https://kotlin.github.io/dokka/1.6.0/developer_guide/extension_points/#creating-documentation-models).\n- All [Documentables](https://kotlin.github.io/dokka/1.6.0/developer_guide/data_model/#documentable-model) are\n  saved in a map by their path (e.g. `com.example.plugin.Class1.function1`) and their extension path.\n- Next, the documentation contents, location in the file, and indents are collected from each documentable\n  in the map.\n- All processors are run in sequence on the collected documentables with their data:\n    - All documentables are iterated over and tag replacement processors, like @include, will replace all tags with new\n      content.\n- Finally, all files from the source are copied over to a destination folder and if there are any modifications that\n  need to be made in a file, the specified ranges for each documentation are replaced with the new documentation.\n\n## Custom processors\n\nYou can create your plugin for the Gradle plugin with your own processors by either extending the\nabstract `TagDocProcessor` class or\nimplementing the `DocProcessor` interface, depending on how much control you need over the docs.\n\nMake sure to depend on the sources by adding the following to your `build.gradle.kts` or `build.gradle` file:\n\n```kts\nrepositories {\n    ..\n    gradlePluginPortal()\n}\n\ndependencies {\n    ..\n    compileOnly(\"nl.jolanrensen.docProcessor:doc-processor-gradle-plugin:{ VERSION }\")\n}\n```\n\nLet's create a small example processor:\n\n```kotlin\npackage com.example.plugin\n\nclass ExampleDocProcessor : TagDocProcessor() {\n\n    /** We'll intercept @example tags. */\n    override fun tagIsSupported(tag: String): Boolean =\n        tag == \"example\"\n\n    /** How `{@inner tags}` are processed. */\n    override fun processInlineTagWithContent(\n        tagWithContent: String,\n        path: String,\n        documentable: DocumentableWrapper,\n    ): String = processContent(tagWithContent)\n\n    /** How `  @normal tags` are processed. */\n    override fun processBlockTagWithContent(\n        tagWithContent: String,\n        path: String,\n        documentable: DocumentableWrapper,\n    ): String = processContent(tagWithContent)\n\n    // We can use the same function for both processInnerTagWithContent and processTagWithContent\n    private fun processContent(tagWithContent: String): String {\n\n        // We can log stuff, if we want to, using https://github.com/oshai/kotlin-logging\n        logger.info { \"Hi from the example logs!\" }\n\n        // We can get the content after the @example tag.\n        val contentWithoutTag = tagWithContent\n            .getTagArguments(tag = \"example\", numberOfArguments = 1)\n            .single()\n            .trimEnd() // remove trailing whitespaces/newlines\n\n        // While we can play with the other arguments, let's just return some simple modified content\n        var newContent =\n            \"Hi from the example doc processor! Here's the content after the @example tag: \\\"$contentWithoutTag\\\"\"\n\n        // Since we trimmed all trailing newlines from the content, we'll add one back if they were there.\n        if (tagWithContent.endsWith(\"\\n\"))\n            newContent += \"\\n\"\n\n        return newContent\n    }\n}\n```\n\nFor the processor to be detectable, we need to add it to the\n`src/main/resources/META-INF/services/nl.jolanrensen.docProcessor.DocProcessor` file:\n\n```\ncom.example.plugin.ExampleDocProcessor\n```\n\nand then publish the project somewhere it can be used in other projects.\n\nAdd the published project as dependency in your other project's `build.gradle.kts` file in your created\ndoc process task (as described in the [How to Use](#how-to-use) section), both in the dependencies\nand in the `processors` list.\n\nNow, if that project contains a function like:\n\n```kotlin\n/**\n * Main function.\n * @example Example\n */\nfun main() {\n    println(\"Hello World!\")\n}\n```\n\nThe output will be:\n\n```kotlin\n\n/**\n * Main function.\n * Hi from the example doc processor! Here's the content after the @example tag: \"Example\"\n */\nfun main() {\n    println(\"Hello World!\")\n}\n```\n\nSee the `defaultProcessor` folder in the project for more examples!\n\n## IntelliJ Plugin (Alpha)\n\nAside from a Gradle plugin, the project also contains an IntelliJ plugin that allows you to preview the rendered\ndocumentation directly in the IDE.\n![image](https://github.com/Jolanrensen/docProcessorGradlePlugin/assets/17594275/7f051063-38c7-4e8b-aeb8-fa6cf14a2566)\n\nCurrently, the only way to try this is by building the plugin yourself from sources and installing it in IntelliJ.\nThe plugin in its current state is unconfigurable and just uses the default processors as shown in the sample above.\nAlso, it uses the IDE engine to resolve references.\nThis is because it's a lot faster than my own engine + Dokka, but it does mean that there might be some differences\nwith the preview and how it will look in the final docs. So, take this into account.\n\nI'm still working on connecting it to the Gradle plugin somehow or provide a way to configure it correctly,\nbut until then, you can use it as is and be more efficient in your documentation writing!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjolanrensen%2Fkodex","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjolanrensen%2Fkodex","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjolanrensen%2Fkodex/lists"}