unstale

npm / @astrojs/markdown-remark

@astrojs/markdown-remark

What changed in @astrojs/markdown-remark 6 to 7, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-30.

15 breaking2 security5 deprecations4 new APIs and options2 performance5 behavior and defaults1 tooling7 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli on npm

@astrojs/markdown-remark 731 changes

Breaking changes 6

  • Code blocks for languages Prism doesn’t support, such as vue or svelte, are displayed as plain text instead of being rendered as HTML.

    7.3.5release notes

  • Dynamic values passed as <script> or <style> children are escaped instead of rendered raw; use set:html to opt back into raw rendering.

    7.3.1release notes

  • Astro no longer installs this package by default because Sätteri is now the default Markdown processor.

    7.0.0upgrade guide

  • Markdown heading ID generation is updated, which may change the IDs generated for headings.

    7.0.0release notes

  • To keep using the unified pipeline, install @astrojs/markdown-remark and set markdown.processor to unified().

    7.0.0upgrade guide

  • This deprecated option still works, but now requires @astrojs/markdown-remark to be installed.

    7.0.0upgrade guide

Security 2

  • Astro: Reflected XSS via unescaped slot names in @astrojs/solid-js

    7.1.2security advisory

  • Nested object and package metadata lookups now ignore prototype keys in content handling and project scaffolding.

    7.1.1release notes

Deprecations 5

  • The top-level option is deprecated; move plugins onto unified({...}) or your preferred plugin processor.

    7.2.0release notes

  • The top-level option is deprecated; move it onto unified({...}) or your preferred plugin processor.

    7.2.0release notes

  • The rehypePlugins option on the MDX integration is deprecated; move it onto unified({...}) or your preferred plugin processor.

    7.2.0release notes

  • The remarkPlugins option on the MDX integration is deprecated; move it onto unified({...}) or your preferred plugin processor.

    7.2.0release notes

  • The remarkRehype option on the MDX integration is deprecated; move it onto unified({...}) or your preferred plugin processor.

    7.2.0release notes

New APIs and options 4

  • Adds the recmaPlugins option for adding recma (estree/JSX) plugins to the MDX compiler.

    7.3.0release notes

  • Adds a configuration option for choosing an alternative Markdown processor; the default remains unified().

    7.2.0release notes

  • The smartypants property now accepts Smartypants options for fine-grained control over typography transformations.

    7.1.0release notes

  • Exposes the fileURL option so callers can specify the file URL used to resolve relative image paths.

    7.0.0release notes

Performance 2

  • Returns a cached highlighter based on Shiki options instead of always creating a new instance, improving performance for sites that heavily use Shiki and code.

    7.0.0release notes

  • Cached Shiki highlighter instances are reused across languages.

    7.0.0release notes

Behavior and default changes 4

  • Unpins @astrojs/* dependencies so versions matching the ^ range can be installed.

    7.3.9release notes

  • YAML parsing now supports timestamps and merge keys, and YAML errors are formatted consistently across Astro, Markdown, MDX, and Markdoc.

    7.3.2release notes

  • The processor now compiles .mdx files itself; projects still need to install @astrojs/mdx to add MDX support.

    7.3.0release notes

  • The processor now compiles .mdx files itself; projects still need to install @astrojs/mdx to add MDX support.

    7.3.0release notes

Tooling 1

  • The timing report now includes measurements for Markdown processing and syntax highlighting.

    7.3.3release notes

Fixes and other changes 7

  • Fixes heading text reporting { as ${ when using the unified() processor, including in getHeadings() and render().headings.

    7.3.10release notes

  • When ignoreElementNames is set, SVG attributes like marker-end are no longer converted to markerEnd.

    7.3.8release notes

  • MDX optimize no longer empties style and script elements nested in static HTML from plugins.

    7.3.8release notes

  • The code block language is correctly escaped in generated class and data-language attributes.

    7.3.5release notes

  • Fixes highlighting for code block languages ending in a symbol, such as c#, c++, and f#.

    7.3.2release notes

  • Fixes an unexpected error caused by using the Code component.

    7.0.0release notes

  • Fixes Prism-generated code blocks incorrectly including the is:raw attribute in the final output.

    7.0.0release notes

@astrojs/markdown-remark 610 changes

Breaking changes 9

  • HAST-only props are no longer directly converted into HTML attributes.

    6.3.10release notes

  • This CSS variable replaces --astro-code-color-background to align with Shiki v1 defaults.

    6.0.0release notes

  • This CSS variable is renamed to --astro-code-background to align with Shiki v1 defaults.

    6.0.0release notes

  • This CSS variable is renamed to --astro-code-foreground to align with Shiki v1 defaults.

    6.0.0release notes

  • This CSS variable replaces --astro-code-color-text to align with Shiki v1 defaults.

    6.0.0release notes

  • The return object exposes codeToHast and codeToHtml for generating either a HAST tree or an HTML string directly.

    6.0.0release notes

  • This API is removed in favour of isFrontmatterValid.

    6.0.0release notes

  • Astro heading metadata in Remark and Rehype plugins moves from vfile.data.__astroHeadings to vfile.data.astro.headings.

    6.0.0release notes

  • Astro image-path metadata moves from vfile.data.imagePaths to vfile.data.astro.imagePaths, and its type changes from Set<string> to string[].

    6.0.0release notes

Behavior and default changes 1

  • Frontmatter parsing is now handled by the package itself.

    6.0.0release notes