npm / @astrojs/markdoc
@astrojs/markdoc
What changed in @astrojs/markdoc 1 to 2, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-20.
7 breaking1 new APIs and options6 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli init@astrojs/markdoc 28 changes
Breaking changes 2
Image handling is updated for Astro 7.4 and requires astro@^7.4.0.
The minimum supported Node.js version is now 22.22.0.
New APIs and options 1
YAML parsing now supports timestamps and merge keys in Markdoc.
Fixes and other changes 5
YAML errors are now formatted consistently across Astro, Markdown, MDX, and Markdoc.
User-written transforms are preserved when a tag or node also specifies a custom render component; only Markdoc’s built-in transforms are removed.
Custom transforms are no longer dropped for tag and node names requiring bracket access; detection recognizes bracket notation, optional chaining and whitespace.
Corrects the dependencies listed in the peerDependencies field.
Fixes a crash when rendering Shiki-highlighted code blocks inside list items.
@astrojs/markdoc 16 changes
Breaking changes 5
Temporary support for Node >=20.19.1 was removed because Stackblitz now uses Node 22 by default.
Updates the Astro peer dependency to 6.0.0, affecting which Astro version is compatible with @astrojs/markdoc.
Markdown heading ID generation is updated, which may change the IDs generated for headings.
When a Markdoc node config specifies both render and transform, render now takes precedence over transform.
Astro v6 upgrades to Vite v7.0 for the development server and production bundler.
Fixes and other changes 1
Custom attribute declarations are synced between same-named table tags and nodes, so defining them on either side avoids validation errors.