preview.nvim/spec
Barrett Ruth 36e49cbd41
fix(presets): add --mathml to pandoc markdown args (#53)
* fix(presets): add `--mathml` to `markdown` and `github` pandoc args

Problem: pandoc's default HTML math renderer cannot handle most TeX and
dumps raw LaTeX source into the output. `--mathjax` and `--katex` are
incompatible with `--embed-resources` because pandoc cannot inline
dynamically-loaded JavaScript modules and fonts.

Solution: add `--mathml` to both `markdown` and `github` preset args.
MathML is rendered natively by all modern browsers with no external
dependencies, making it the only math option compatible with
self-contained HTML output.

* docs(presets): add math rendering section with KaTeX recipe

Problem: the `markdown` and `github` presets now default to `--mathml`
but users may want KaTeX or MathJax rendering instead, and the
incompatibility with `--embed-resources` is non-obvious.

Solution: add a `preview-math` section to the presets docs explaining
the default, why `--katex`/`--mathjax` require dropping
`--embed-resources`, and a concrete recipe for KaTeX with `github`.

* test(presets): update `markdown` and `github` args assertions for `--mathml`
2026-03-06 13:39:22 -05:00
..
commands_spec.lua fix: lifecycle cleanup and defensive runtime checks (#29) 2026-03-04 14:02:16 -05:00
compiler_spec.lua refactor(compiler): replace 7 state tables with unified BufState (#52) 2026-03-05 23:58:19 -05:00
diagnostic_spec.lua feat: rename 2026-03-02 21:23:40 -05:00
helpers.lua feat: rename watch → toggle, auto-compile on start, built-in opener 2026-03-02 23:37:44 -05:00
init_spec.lua fix: lifecycle cleanup and defensive runtime checks (#29) 2026-03-04 14:02:16 -05:00
minimal_init.lua ci: format 2026-03-01 17:22:59 -05:00
presets_spec.lua fix(presets): add --mathml to pandoc markdown args (#53) 2026-03-06 13:39:22 -05:00
reload_spec.lua fix(ci): resolve lua-language-server warnings (#32) 2026-03-04 14:28:52 -05:00