OutputConfig

class OutputConfig(val kslides: KSlides)

Controls where and how presentations are emitted. Configured via com.kslides.KSlides.output. Both output modes can be enabled simultaneously; if neither is enabled a warning is logged and no output is produced.

Constructors

Link copied to clipboard
constructor(kslides: KSlides)

Properties

Link copied to clipboard

Log level passed to Ktor's CallLogging plugin.

Link copied to clipboard

Directory on the classpath from which static content is served in HTTP mode.

Link copied to clipboard

When true (and enableHttp), served pages embed a live-reload client that reconnects to a websocket and refreshes the browser — restoring the current slide — whenever the server restarts. Intended for local authoring only: leave false for published output, since with enableFileSystem on the reload client is also written into the static pages under outputDir. Default false.

Link copied to clipboard

When true, write static HTML files under outputDir. Default true.

Link copied to clipboard

When true, start a Ktor HTTP server serving the presentations. Default true.

Link copied to clipboard

When true (and enableHttp), enable follow-along presenting: the presenter opens a deck with ?present=<token> and every other visitor's browser follows the presenter's slide and fragment position live, with a break-away/rejoin toggle. The presenter URLs (with the token) are logged at server startup. Has no effect on filesystem output. Default false.

Link copied to clipboard

HTTP port. Overridden at runtime by the PORT environment variable (Heroku convention).

Link copied to clipboard

Subdirectory of outputDir where Kroki diagram images are written.

Link copied to clipboard

back-reference to the owning KSlides instance.

Link copied to clipboard

Subdirectory of outputDir where Lets-Plot iframe HTML files are written.

Link copied to clipboard

Root directory for filesystem-mode output. Default "docs" (GitHub Pages / Netlify friendly).

Link copied to clipboard

PDF export settings, consumed by the kslides-export module. Configured via pdf.

Link copied to clipboard

Subdirectory of outputDir where Kotlin Playground iframe HTML files are written.

Link copied to clipboard

The presenter token for followAlong. Blank (the default) generates a random token per launch; set it explicitly when the presenter needs a predictable URL (e.g. typing it on another device). This is lightweight, demo-grade auth — the token travels in the URL.

Link copied to clipboard

Directory holding the bundled reveal.js assets, in filesystem mode only. A generated page links to them through this directory, reached from wherever the page itself sits. HTTP mode ignores this and serves the assets from the classpath via defaultHttpRoot instead.

Functions

Link copied to clipboard
fun pdf(block: PdfConfig.() -> Unit)

Configure PDF export (page size, output directory, per-presentation opt-out). See PdfConfig.