Runs a full documentation build.
@eryx/eryxdoc Module
JSON
Docgen build engine — the programmatic API.
Use this module when you want to drive eryxdoc from your own script instead of going through main.luau's CLI.
local eryxdoc = require("./eryxdoc")
eryxdoc.build({
title = "My Docs",
modules = "./src/modules",
articles = "./docs",
output = "./site",
prefix = "@mylib",
})
Summary
Functions
API Reference
Functions
eryxdoc.build
Parameters
The build configuration.
Returns
{ warnings: { string }, moduleCount: number, articleCount: number }
eryxdoc.getDefaultTheme
Types
PageMeta
Metadata for a single page, used for tags and OpenGraph. Returned by metaGenerator or built from defaults.
PageContext
Context passed to the metaGenerator callback so it can decide per-page meta.
OpenGraphConfig
Config
Required
Content sources
Site settings
Theming
HTML injections
OpenGraph / SEO
Optional callbacks that return per-page meta for each page type. Overrides global openGraph defaults for that page. Return nil fields to fall back to the global defaults.
Template customisation
Versioning When set, the build output goes into output/{version.name}/ and a versions.json manifest is written/updated at the output root. The version picker in the header reads this manifest.
Redirects Each entry generates an HTML redirect stub at the "from" path. Useful when pages are moved to keep old URLs working.
Build hooks Callbacks invoked at key points during the build. All are optional.
Build options