0.8.0-alpha.1 - 2026-06-10
Pre-release
Pre-release
Release Notes
This alpha starts the 0.8 line with a smaller, clearer feature surface and a real Typst package path. The default Rust crate behavior remains Mermaid-compatible, while no-default and Typst-oriented builds can now avoid host-only and full-config dependencies.
Added
- Added an experimental
merman-typst-pluginWebAssembly bridge and local Typst package surface. The package supports#mermaid(...)for embedded SVG images,#show raw.where(lang: "mermaid"): show-mermaid-blocks(...)for Mermaid fenced code blocks,mermaid-svg(...)for raw SVG export,mermaid-result(...)for structured render payloads,validate-mermaid(...)for validation-only workflows, anderror-mode: "panic" | "placeholder" | "text"for draft-friendly error handling. - Added
xtask build-typst-package, which builds the Typst-compatible wasm and assemblesdist/typst/merman/<version>withtypst.toml,lib.typ, README, examples, licenses, and the wasm plugin. - Started the Typst package on an independent
0.1.xversion track instead of locking it to Cargo prerelease versions, because Typst imports require numeric package versions. - Added CI smoke coverage for the Typst package: package build, wasm ABI/size gate, example compilation, and
@previewimport smoke. - Added Typst examples for basic usage, raw blocks, options, print-friendly output, slide-sized dark output, SVG export, and structured render results.
Changed
- Consolidated
merman-core's public feature surface into coarse-grained profiles:full,full-config,full-sanitization, andhost. - Kept default builds Mermaid-compatible with
full + host, while making--no-default-featuresa meaningful pure-WASM/Typst starting point. - Split
merman-render'score-fullforwarding from its host feature so Typst render builds can keep parser/layout/SVG support without pulling full config and sanitizer dependencies. - Made render/layout timing and RoughJS seed-zero randomness deterministic in no-host wasm profiles, while preserving host behavior behind explicit host features.
- Collapsed the Typst wasm rendering surface to
render_svg_jsonplusvalidate_json; the older directrender_svgexport was removed before the Typst package was published so all Typst rendering uses one structured result path.
Feature guidance:
- Most Rust applications should keep defaults. That means
mermanstill enables Mermaid-compatible full config/sanitization and host behavior. - Use
default-features = falsewhen embedding the parser/core in a pure wasm environment that cannot import host time, random, URL, YAML, JSON5, or sanitizer dependencies. - Enable
renderwithoutcore-fullfor Typst-like SVG rendering where the source and options are trusted or already normalized and package size matters. - Enable
core-fullwhen you need Mermaid's broad config/frontmatter surface, YAML/JSON5 parsing, or full sanitizer parity. - Enable
hostwhen the renderer should use local wall-clock behavior or host randomness. Leave it off for deterministic wasm output.
WASM Footprint & Typst Compatibility
- Slimmed the pure/Typst-oriented core profile significantly. A Typst-compatible
wasm32-unknown-unknownsemantic probe built onmerman-core --no-default-featuresmeasured 1,737,728 bytes raw (570,804 bytes gzip), while the metadata probe measured 1,736,363 bytes raw (570,150 bytes gzip). - A core-only no-import probe measured 1,729,398 bytes raw (567,208 bytes gzip).
- The Typst-oriented probe imports only Typst's two
wasm-minimal-protocolhost callbacks and no longer pullswasm-bindgen,js-sys,serde_yaml,json5,lol_html,url,uuid, orweb-timethrough the pure/no-default core path. - The default minimal Typst package build (
render, nocore-full, no host) now measures about **7.02 MB raw** and **1.93 MB gzip** and passes the Typst wasm ABI gate with only the twowasm-minimal-protocol` imports. - The opt-in full no-host Typst render build (
render + core-full) measures 8,073,841 bytes raw (2,349,176 bytes gzip) with the same Typst-only import surface.
Fixed
- Corrected web package documentation to use the published
@mermanjs/webnpm package name. - Avoided clipped Flowchart edge labels in Linux/Firefox browser previews. Thanks @aurabindo for reporting #2.
- Limited CSS override cleanup to
<style>blocks andstyleattributes so ordinary SVG text and metadata containing!importantstay intact. - Scoped embedded icon IDs so repeated Flowchart and Architecture icons do not collide inside one SVG.
- Scoped Sankey generated IDs and Sequence debug markers for safer inline SVG embedding.
Install merman-cli 0.8.0-alpha.1
Install prebuilt binaries via shell script
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/Latias94/merman/releases/download/v0.8.0-alpha.1/merman-cli-installer.sh | shInstall prebuilt binaries via powershell script
powershell -ExecutionPolicy Bypass -c "irm https://github.com/Latias94/merman/releases/download/v0.8.0-alpha.1/merman-cli-installer.ps1 | iex"Download merman-cli 0.8.0-alpha.1
| File | Platform | Checksum |
|---|---|---|
| merman-cli-aarch64-apple-darwin.tar.xz | Apple Silicon macOS | checksum |
| merman-cli-x86_64-apple-darwin.tar.xz | Intel macOS | checksum |
| merman-cli-x86_64-pc-windows-msvc.zip | x64 Windows | checksum |
| merman-cli-x86_64-unknown-linux-gnu.tar.xz | x64 Linux | checksum |