Skip to content

Generator extensions: user-defined output generators #1216

Description

@gennaroprota

Splitting this out per the #1128 / #1196 discussion. Transformation extensions (scripts that mutate the corpus) shipped in #1196. Generator extensions are the separate capability: letting users add or customize an output generator without touching MrDocs core.

The concrete first approach is tracked in #1082 (format-agnostic Handlebars generator: a base generator parameterized by format, templates under share/mrdocs/addons/generator/<format>/, an escape map, supplemental addon directories; e.g. a Markdown generator); it shipped as data-driven generators in #1197. This issue is the umbrella for the capability, which now has two flavors: data-driven (template) generators (#1197) and script-driven generators (#1218).

Open questions (resolved by #1197 and #1218):

  • Template-only generators (the Format-agnostic Handlebars generator extension #1082 flavor) vs script-driven generators (interpreter hooks).
  • How a custom format registers and how output file extensions map to template directories.
  • Escaping rules per format.
  • Interaction with addon layering / supplemental directories.

Distinct from #1210 (richer transformation entry points), #1213, and #1215, which are all about transformation extensions, not generators.

Metadata

Metadata

Assignees

No one assigned

    Labels

    featNew capability or enhancement

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status
    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions