Skip to content

MI-T3: MDX + HTML export (SSG-generation formats) #58

Description

@coderhd

Parent

#26 — H0 — Markdown Import/Export (full round-trip)

What to build

Two more export formats on top of the Markdown export, for the SSG-generation usecase (author docs in Lekhan, build them with Docusaurus/MDX toolchains elsewhere):

  • MDX (.mdx): the same markdown body with inline HTML preserved (valid MDX), saved with the .mdx extension.
  • HTML (.html): the editor's rendered HTML wrapped in a minimal standalone document.

Both are ungated (free on every tier), alongside the Markdown/DOCX/PDF items in the same Export menu.

Acceptance criteria

  • Export menu gains Download as MDX (.mdx) and Download as HTML (.html).
  • MDX file is the markdown serialization (inline HTML preserved) with a .mdx extension; usable as a Docusaurus/MDX doc source.
  • HTML file is editor.getHTML() wrapped in a minimal <html> document, saved as .html.
  • Both formats respect the filename-slugification rule from the Markdown export.
  • Focused unit tests pass; npm run lint and npm run build green.

Blocked by

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions