Skip to main content

Getting started

Requirements​

  • JDK 21 or newer
  • Gradle (the wrapper is checked in)

Node is provided by the Kotlin/JS plugin; the Docusaurus packages come from the npm workspace the same plugin installs.

Build the site​

./gradlew :docs:docusaurusBuild

The static site is written to build/js/docusaurus/docs/build.

Develop with a dev server​

./gradlew :docs:docusaurusStart

Docusaurus watches the site directory, so Markdown edits reload the page. Kotlin changes need a new build of the module first:

./gradlew :docs:docusaurusSite :docs:docusaurusStart

Where things live​

PathContents
src/jsMain/kotlin/io/github/shijianjs/ktjs/docusaurus/docs/Config.ktSite configuration and sidebar
src/jsMain/resources/docsMarkdown pages
src/jsMain/resources/cssExtra stylesheets
src/jsMain/resources/staticFiles copied as-is into the build