Skip to content

mdrefine 0.1.0-beta.3

Pre-release
Pre-release

Choose a tag to compare

@github-actions github-actions released this 18 Sep 20:46
Immutable release. Only release title and notes can be modified.
a4ef35e

mdrefine 0.1.0-beta.3

Third public beta of Markdown Tools. npm package: mdrefine; executable:
mdtools. Requires Node.js 22.12 or newer. Upgrade with:

npm install --save-dev --save-exact mdrefine@0.1.0-beta.3

Correct wrap diagnostics

Protected paragraphs now distinguish breakable prose from indivisible inline
atoms. A hard-break paragraph whose only over-width content is a long link, code
span, or other protected atom no longer triggers reportUnreflowed. That
overflow follows reportUnbreakable, including when reflow is skipped. A
paragraph containing both causes can report both when enabled.

Whitespace inside protected inline nodes is not a wrapping opportunity.
Container prefixes count toward width; hard-break markers are excluded from
protected-line width. Both diagnostic options remain disabled by default and
propose no edits. Protected paragraph source remains unchanged.

Fixed in PR #36,
resolving #34.
Regression coverage includes both hard-break forms, LF/CRLF, lists, quotes, task
items, Unicode width measurement, and Obsidian's strict-line-break gate.

Faster formatting

The formatter reuses the current parsed document between phases and for final
diagnostics. It parses each changed candidate and validates its meaning before
accepting it. Edit-range, overlap, oscillation, and convergence checks remain in
force; no persistent cache or worker pool is introduced.

A warmed synthetic benchmark improved approximately 2.3 times for input needing
edits and 2.6 times for already-formatted input, with identical result hashes.
On the reporter's 8,362-document, 36 MB workspace, format --check --json fell
from 314 to 121 seconds, with the same 6,960 would-change files and no remaining
diagnostics after formatting. These are workload-specific results, not a
throughput guarantee.

Implemented in
PR #37, resolving
#35.
Original-workload validation in
#23
also confirms the beta.2 indexing improvements and correct link diagnostics; the
performance issue is now closed. The source checkout includes
scripts/benchmark-format.mjs for reproducible formatting measurements.

Compatibility

No dependency, public API, configuration-schema, or Node.js minimum changes.
Existing beta.2 configurations remain valid. Consumers enabling wrap diagnostics
may see findings move from reportUnreflowed to reportUnbreakable; this is
the intentional classification correction described above.

The API and configuration remain provisional. Semantic guards, conservative
handling of unsupported constructs, and Obsidian's verified strict-line-break
requirement remain in force. Repository agent instructions now also prohibit
self-references in GitHub issue and PR posts.

🤖 Generated with GPT-6 via Codex