KSlides
Root orchestrator for a set of presentations. Instances are not meant to be constructed directly — use the kslides top-level function instead, which applies the DSL block and then triggers the configured output modes.
Holds global configuration (kslidesConfig, presentationConfig, output), shared CSS (css), and the collection of Presentation definitions produced by each presentation block. Also caches iframe and Kroki content so repeated lookups from the Ktor server do not re-execute expensive content generators.
Properties
The output configuration populated by the output {} block. Public so that tooling built on buildKSlides (e.g. kslides-export) can read it after the DSL has been evaluated.
The URL paths of all registered presentations (e.g. "/", "/demo.html"), in declaration order. Populated once buildKSlides/kslides has evaluated the DSL. Public for tooling (e.g. kslides-export) that iterates the presentations served by startHttpServer.
Functions
Release the lazily-created Ktor HttpClient if it was ever initialized (it is created only when a diagram{} block POSTs to Kroki). filesystem-only runs close it automatically once slides are written; HTTP mode keeps it alive for the server's lifetime. Idempotent and safe to call when the client was never created. Lets consumers use kslides { … } results with .use { }.
Configure values that apply to all presentations (e.g. static asset roots, Playground URL, Kroki URL, Lets-Plot JS version, HTTP client timeout). The block is evaluated after the full kslides {} DSL so that later kslidesConfig{} calls override earlier ones.
Configure how the presentations are emitted: filesystem mode (enableFileSystem), HTTP mode (enableHttp), output directory, HTTP port, etc.
Register a Presentation definition. Each call adds one entry; the path assigned inside the block determines its URL (HTTP mode) or output filename (filesystem mode).
Default PresentationConfig applied to every Presentation. Per-presentation overrides take precedence; see the configuration-cascade description in the project README.
Start the same Ktor HTTP server that output { enableHttp = true } runs, serving every registered presentation plus the bundled static assets. When com.kslides.config.OutputConfig.followAlong is enabled, the presenter URLs (with the token) are logged against the actual bound port.