- #17896
a548223Thanks @matthewp! - Fixes<script>/<style>rendering in MDX so that only literal content (including content injected by remark/rehype plugins) is treated as trusted markup. A dynamic value passed as a<script>/<style>child (e.g.<script>{value}</script>) is now escaped like any other element's content instead of being rendered raw. Useset:htmlto explicitly opt a dynamic value back into raw rendering.
-
#17262
f8e9458Thanks @Princesseuh! - Adds MDX rendering to theunified()andsatteri()processors.Both processors now compile
.mdxfiles themselves. You still need to install@astrojs/mdxto add MDX support to your project. -
#17262
f8e9458Thanks @Princesseuh! - Adds arecmaPluginsoption tounified()for adding recma (estree/JSX) plugins to the MDX compiler.
- Updated dependencies [
f8e9458]:- @astrojs/internal-helpers@0.11.0
- Updated dependencies [
05763a0]:- @astrojs/internal-helpers@0.10.4
- Updated dependencies [
8c193f6]:- @astrojs/internal-helpers@0.10.3
- Updated dependencies [
c895b12]:- @astrojs/internal-helpers@0.10.2
- Updated dependencies [
eb6f97e]:- @astrojs/internal-helpers@0.10.1
-
#16848
f732f3cThanks @Princesseuh! - Adds a newmarkdown.processorconfiguration option, allowing you to choose an alternative Markdown processor.Websites with many Markdown/MDX files tend to be slow to build because the unified ecosystem (e.g., remark, rehype) is slow to process. This feature introduces the ability to replace this part of the build pipeline with another processor.
The default processor is
unified(). This means that existing configurations remain unchanged and your remark/rehype plugins continue to work.// astro.config.mjs import { defineConfig } from 'astro/config'; import { unified } from '@astrojs/markdown-remark'; import remarkToc from 'remark-toc'; export default defineConfig({ markdown: { processor: unified({ remarkPlugins: [remarkToc], }), }, });
In addition to this new configuration option, Astro provides a new alternative processor based on Rust: Sätteri. You can choose to use it now by installing
@astrojs/markdown-satteri, importing thesatteri()processor, and adapting your existing configuration:// astro.config.mjs import { defineConfig } from 'astro/config'; import { satteri } from '@astrojs/markdown-satteri'; export default defineConfig({ markdown: { processor: satteri({ features: { directive: true }, }), }, });
This processor does not support the remark and rehype plugins. This means you may need to convert them to MDAST or HAST plugins to retain your current functionality.
The existing top-level
markdown.remarkPlugins,markdown.rehypePlugins,markdown.remarkRehype,markdown.gfm, andmarkdown.smartypantsoptions still work, but are now deprecated and will be removed in a future major update. The matchingremarkPlugins,rehypePlugins, andremarkRehypeoptions on the MDX integration are also deprecated for the same reason. To anticipate their removal, move them ontounified({...})(or your preferred plugin processor) :// astro.config.mjs import { defineConfig } from 'astro/config'; import remarkToc from 'remark-toc'; import rehypeSlug from 'rehype-slug'; + import { unified } from '@astrojs/markdown-remark'; export default defineConfig({ markdown: { + processor: unified({ + remarkPlugins: [remarkToc], + rehypePlugins: [rehypeSlug], + remarkRehype: true, + gfm: true, + smartypants: true, + }), - remarkPlugins: [remarkToc], - rehypePlugins: [rehypeSlug], - remarkRehype: true, - gfm: true, - smartypants: true, }, });For more information on enabling and using this feature in your project, see our Markdown guide. To give feedback on this new Rust processor, see the Native Markdown / MDX parsing and processing RFC.
- Updated dependencies [
f732f3c]:- @astrojs/internal-helpers@0.10.0
-
#15723
9256345Thanks @rururux! - Updates internal type usage from@astrojs/prism. -
Updated dependencies [
d365c97,9256345]:- @astrojs/internal-helpers@0.9.1
- @astrojs/prism@4.0.2
-
#16419
f3485c3Thanks @matthewp! - Hardens nested object and package metadata lookups to ignore prototype keys in content handling and project scaffolding -
Updated dependencies [
99464ed,f3485c3]:- @astrojs/internal-helpers@0.9.0
-
#15340
10a1a5aThanks @trueberryless! - UpdatescreateMarkdownProcessorto support advanced SmartyPants options.The
smartypantsproperty inAstroMarkdownOptionsnow acceptsSmartypantsoptions, allowing fine-grained control over typography transformations (backticks, dashes, ellipses, and quotes).import { createMarkdownProcessor } from '@astrojs/markdown-remark'; const processor = await createMarkdownProcessor({ smartypants: { backticks: 'all', dashes: 'oldschool', ellipses: 'unspaced', openingQuotes: { double: '«', single: '‹' }, closingQuotes: { double: '»', single: '›' }, quotes: false, }, });
For the up-to-date supported properties, check out the
retext-smartypantsoptions.
- Updated dependencies [
d3c7de9]:- @astrojs/prism@4.0.1
-
#14494
727b0a2Thanks @florian-lefebvre! - Updates Markdown heading ID generation - (v6 upgrade guidance) -
#15726
6f19eccThanks @ocavue! - Updates dependencyshikito v4Check Shiki's upgrade guide.
-
#15277
cb99214Thanks @ematipico! - Fixes an issue where the functioncreateShikiHighlighterwould always create a new Shiki highlighter instance. Now the function returns a cached version of the highlighter based on the Shiki options. This should improve the performance for sites that heavily rely on Shiki and code in their pages. -
#15332
7c55f80Thanks @matthewp! - Exposes thefileURLoption inMarkdownProcessorRenderOptions, allowing callers to specify the file URL for resolving relative image paths.
-
#15297
80f0225Thanks @rururux! - Fixes a case where code blocks generated by prism would include theis:rawattribute in the final output -
#15676
1fa4177Thanks @rururux! - Fixes an issue where the use of theCodecomponent would result in an unexpected error. -
#15651
f94d3c5Thanks @ocavue! - Reuses cached Shiki highlighter instances across languages. -
Updated dependencies [
bbb5811,4ebc1e3,11efb05,4e7f3e8,a164c77,cf6ea6b,e131261,a18d727,240c317,745e632]:- @astrojs/prism@4.0.0
- @astrojs/internal-helpers@0.8.0
- Updated dependencies [
745e632]:- @astrojs/internal-helpers@0.8.0-beta.2
-
#15726
6f19eccThanks @ocavue! - Updates dependencyshikito v4Check Shiki's upgrade guide.
- #15676
1fa4177Thanks @rururux! - Fixes an issue where the use of theCodecomponent would result in an unexpected error.
- #15451
84d6efdThanks @ematipico! - Changes how styles applied to code blocks are emitted to support CSP - (v6 upgrade guidance)
- #15297
80f0225Thanks @rururux! - Fixes a case where code blocks generated by prism would include theis:rawattribute in the final output
- Updated dependencies [
240c317]:- @astrojs/internal-helpers@0.8.0-beta.0
- #15332
7c55f80Thanks @matthewp! - Exposes thefileURLoption inMarkdownProcessorRenderOptions, allowing callers to specify the file URL for resolving relative image paths.
- #15277
cb99214Thanks @ematipico! - Fixes an issue where the functioncreateShikiHighlighterwould always create a new Shiki highlighter instance. Now the function returns a cached version of the highlighter based on the Shiki options. This should improve the performance for sites that heavily rely on Shiki and code in their pages.
- Updated dependencies [
11efb05]:- @astrojs/prism@4.0.0-beta.2
-
Updated dependencies [
bbb5811]:- @astrojs/prism@4.0.0-beta.1
- #14494
727b0a2Thanks @florian-lefebvre! - Updates Markdown heading ID generation - (v6 upgrade guidance)
- Updated dependencies [
e131261]:- @astrojs/prism@4.0.0-alpha.0
- #14902
d8305f8Thanks @tuyuritio! - Prevents HAST-only props from being directly converted into HTML attributes
- Updated dependencies [
b8ca69b]:- @astrojs/internal-helpers@0.7.4
- Updated dependencies [
1e2499e]:- @astrojs/internal-helpers@0.7.3
- Updated dependencies [
4d16de7]:- @astrojs/internal-helpers@0.7.2
- Updated dependencies [
0567fb7]:- @astrojs/internal-helpers@0.7.1
- Updated dependencies [
f4e8889]:- @astrojs/internal-helpers@0.7.0
-
#13941
6bd5f75Thanks @aditsachde! - Adds support for TOML files to Astro's built-inglob()andfile()content loaders.In Astro 5.2, Astro added support for using TOML frontmatter in Markdown files instead of YAML. However, if you wanted to use TOML files as local content collection entries themselves, you needed to write your own loader.
Astro 5.12 now directly supports loading data from TOML files in content collections in both the
glob()and thefile()loaders.If you had added your own TOML content parser for the
file()loader, you can now remove it as this functionality is now included:// src/content.config.ts import { defineCollection } from "astro:content"; import { file } from "astro/loaders"; - import { parse as parseToml } from "toml"; const dogs = defineCollection({ - loader: file("src/data/dogs.toml", { parser: (text) => parseToml(text) }), + loader: file("src/data/dogs.toml") schema: /* ... */ })Note that TOML does not support top-level arrays. Instead, the
file()loader considers each top-level table to be an independent entry. The table header is populated in theidfield of the entry object.See Astro's content collections guide for more information on using the built-in content loaders.
- Updated dependencies [
3c3b492]:- @astrojs/prism@3.3.0
- #13448
91c9503Thanks @ematipico! - Upgrade to shiki v3
-
#13352
cb886dcThanks @delucis! - Adds support for a newexperimental.headingIdCompatflagBy default, Astro removes a trailing
-from the end of IDs it generates for headings ending with special characters. This differs from the behavior of common Markdown processors.You can now disable this behavior with a new configuration flag:
// astro.config.mjs import { defineConfig } from 'astro/config'; export default defineConfig({ experimental: { headingIdCompat: true, }, });
This can be useful when heading IDs and anchor links need to behave consistently across your site and other platforms such as GitHub and npm.
If you are using the
rehypeHeadingIdsplugin directly, you can also pass this new option:// astro.config.mjs import { defineConfig } from 'astro/config'; import { rehypeHeadingIds } from '@astrojs/markdown-remark'; import { otherPluginThatReliesOnHeadingIDs } from 'some/plugin/source'; export default defineConfig({ markdown: { rehypePlugins: [ [rehypeHeadingIds, { experimentalHeadingIdCompat: true }], otherPluginThatReliesOnHeadingIDs, ], }, });
-
#13311
a3327ffThanks @chrisirhc! - Adds a new configuration option for Markdown syntax highlightingexcludeLangsThis option provides better support for diagramming tools that rely on Markdown code blocks, such as Mermaid.js and D2 by allowing you to exclude specific languages from Astro's default syntax highlighting.
This option allows you to avoid rendering conflicts with tools that depend on the code not being highlighted without forcing you to disable syntax highlighting for other code blocks.
The following example configuration will exclude highlighting for
mermaidandmathcode blocks:import { defineConfig } from 'astro/config'; export default defineConfig({ markdown: { syntaxHighlight: { type: 'shiki', excludeLangs: ['mermaid', 'math'], }, }, });
Read more about this new option in the Markdown syntax highlighting configuration docs.
- Updated dependencies [
042d1de]:- @astrojs/internal-helpers@0.6.1
-
#13254
1e11f5eThanks @p0lyw0lf! - Adds remote image optimization in MarkdownPreviously, an internal remark plugin only looked for images in
![]()syntax that referred to a relative file path. This meant that only local images stored insrc/were passed through to an internal rehype plugin that would transform them for later processing by Astro's image service.Now, the plugins recognize and transform both local and remote images using this syntax. Only authorized remote images specified in your config are transformed; remote images from other sources will not be processed.
While not configurable at this time, this process outputs two separate metadata fields (
localImagePathsandremoteImagePaths) which allow for the possibility of controlling the behavior of each type of image separately in the future.
- Updated dependencies [
1e11f5e]:- @astrojs/internal-helpers@0.6.0
-
#12850
db252e0Thanks @colinbate! - Adds support for TOML frontmatter in.mdand.mdxfilesAstro 5.2 automatically identifies the format of your Markdown and MDX frontmatter based on the delimiter used. With
+++as a delimiter (instead of the---YAML code fence), your frontmatter will automatically be recognized and parsed as TOML.This is useful for adding existing content files with TOML frontmatter to your project from another framework such as Hugo.
TOML frontmatter can also be used with content collections, and files with different frontmatter languages can live together in the same project.
No configuration is required to use TOML frontmatter in your content files. Your delimiter will indicate your chosen frontmatter language:
+++ date = 2025-01-30 title = 'Use TOML frontmatter in Astro!' [author] name = 'Colin Bate' +++ # Support for TOML frontmatter is here!
- #12361
3d89e62Thanks @LunaticMuch! - Upgrades theesbuildversion to matchvite
-
#12646
f13417bThanks @bluwy! - Avoids parsing frontmatter that are not at the top of a file -
#12570
87231b1Thanks @GrimLink! - Removes trailing new line in code blocks to prevent generating a trailing empty<span />tag -
#12664
a71e9b9Thanks @bluwy! - Fixes frontmatter parsing if file is encoded in UTF8 with BOM
-
#11861
3ab3b4eThanks @bluwy! - Cleans up Astro-specific metadata attached tovfile.datain Remark and Rehype plugins. Previously, the metadata was attached in different locations with inconsistent names. The metadata is now renamed as below:vfile.data.__astroHeadings->vfile.data.astro.headingsvfile.data.imagePaths->vfile.data.astro.imagePaths
The types of
imagePathshas also been updated fromSet<string>tostring[]. Thevfile.data.astro.frontmattermetadata is left unchanged.While we don't consider these APIs public, they can be accessed by Remark and Rehype plugins that want to re-use Astro's metadata. If you are using these APIs, make sure to access them in the new locations.
-
#12008
5608338Thanks @Princesseuh! - Welcome to the Astro 5 beta! This release has no changes from the latest alpha of this package, but it does bring us one step closer to the final, stable release.Starting from this release, no breaking changes will be introduced unless absolutely necessary.
To learn how to upgrade, check out the Astro v5.0 upgrade guide in our beta docs site.
-
#11825
560ef15Thanks @bluwy! - Updates return object ofcreateShikiHighlighterascodeToHastandcodeToHtmlto allow generating either the hast or html string directly -
#11661
83a2a64Thanks @bluwy! - Renames the following CSS variables theme color token names to better align with the Shiki v1 defaults:--astro-code-color-text=>--astro-code-foreground--astro-code-color-background=>--astro-code-background
You can perform a global find and replace in your project to migrate to the new token names.
-
#11861
3ab3b4eThanks @bluwy! - RemovesInvalidAstroDataError,safelyGetAstroData, andsetVfileFrontmatterAPIs in favour ofisFrontmatterValid
-
#12075
a19530eThanks @bluwy! - Parses frontmatter ourselves -
Updated dependencies [
827093e]:- @astrojs/prism@3.2.0
- Updated dependencies [
827093e]:- @astrojs/prism@3.2.0-beta.0
-
#12008
5608338Thanks @Princesseuh! - Welcome to the Astro 5 beta! This release has no changes from the latest alpha of this package, but it does bring us one step closer to the final, stable release.Starting from this release, no breaking changes will be introduced unless absolutely necessary.
To learn how to upgrade, check out the Astro v5.0 upgrade guide in our beta docs site.
-
#11861
3ab3b4eThanks @bluwy! - Cleans up Astro-specific metadata attached tovfile.datain Remark and Rehype plugins. Previously, the metadata was attached in different locations with inconsistent names. The metadata is now renamed as below:vfile.data.__astroHeadings->vfile.data.astro.headingsvfile.data.imagePaths->vfile.data.astro.imagePaths
The types of
imagePathshas also been updated fromSet<string>tostring[]. Thevfile.data.astro.frontmattermetadata is left unchanged.While we don't consider these APIs public, they can be accessed by Remark and Rehype plugins that want to re-use Astro's metadata. If you are using these APIs, make sure to access them in the new locations.
-
#11825
560ef15Thanks @bluwy! - Updates return object ofcreateShikiHighlighterascodeToHastandcodeToHtmlto allow generating either the hast or html string directly -
#11861
3ab3b4eThanks @bluwy! - RemovesInvalidAstroDataError,safelyGetAstroData, andsetVfileFrontmatterAPIs in favour ofisFrontmatterValid
-
#11661
83a2a64Thanks @bluwy! - Renames the following CSS variables theme color token names to better align with the Shiki v1 defaults:--astro-code-color-text=>--astro-code-foreground--astro-code-color-background=>--astro-code-background
You can perform a global find and replace in your project to migrate to the new token names.
-
#12039
710a1a1Thanks @ematipico! - Adds amarkdown.shikiConfig.langAliasoption that allows aliasing a non-supported code language to a known language. This is useful when the language of your code samples is not a built-in Shiki language, but you want your Markdown source to contain an accurate language while also displaying syntax highlighting.The following example configures Shiki to highlight
cjscode blocks using thejavascriptsyntax highlighter:import { defineConfig } from 'astro/config'; export default defineConfig({ markdown: { shikiConfig: { langAlias: { cjs: 'javascript', }, }, }, });
Then in your Markdown, you can use the alias as the language for a code block for syntax highlighting:
```cjs 'use strict'; function commonJs() { return 'I am a commonjs file'; } ```
-
#11341
49b5145Thanks @madcampos! - Adds support for Shiki'sdefaultColoroption.This option allows you to override the values of a theme's inline style, adding only CSS variables to give you more flexibility in applying multiple color themes.
Configure
defaultColor: falsein your Shiki config to apply throughout your site, or pass to Astro's built-in<Code>component to style an individual code block.import { defineConfig } from 'astro/config'; export default defineConfig({ markdown: { shikiConfig: { themes: { light: 'github-light', dark: 'github-dark', }, defaultColor: false, }, }, });
--- import { Code } from 'astro:components'; --- <Code code={`const useMyColors = true`} lang="js" defaultColor={false} />
- #11310
b6afe6aThanks @bluwy! - Handles encoded image paths in internal rehype plugins and return decoded paths from markdown vfile'sdata.imagePaths
-
#10538
ccafa8d230f65c9302421a0ce0a0adc5824bfd55Thanks @604qgc! - Adds adata-languageattribute on the renderedpreelements to expose the highlighted syntax language.For example, the following Markdown code block will expose
data-language="python":\```python def func(): print('Hello Astro!') \```This allows retrieving the language in a rehype plugin from
node.properties.dataLanguageby accessing the<pre>element using{ tagName: "pre" }:// myRehypePre.js import { visit } from "unist-util-visit"; export default function myRehypePre() { return (tree) => { visit(tree, { tagName: "pre" }, (node) => { const lang = node.properties.dataLanguage; [...] }); }; }
Note: The
<pre>element is not exposed when using Astro's<Code />component which outputs flattened HTML.The
data-languageattribute may also be used in css rules:pre::before { content: attr(data-language); } pre[data-language='javascript'] { font-size: 2rem; }
- Updated dependencies [
683d51a5eecafbbfbfed3910a3f1fbf0b3531b99]:- @astrojs/prism@3.1.0
-
#10629
2cf116f80cb5e421ab5cc5eb4a654e7b78c1b8deThanks @bluwy! - Removes deprecated APIs includingremarkShiki,remarkPrism,replaceCssVariablesand several unused types -
#10618
374efcdff9625ca43309d89e3b9cfc9174351512Thanks @43081j! - Updates Shiki syntax highlighting to lazily load shiki languages by default (only preloadingplaintext). Additionally, thecreateShikiHighlighter()API now returns an asynchronoushighlight()function due to this.
- #10540
c585528f446ccca3d4c643f4af5d550b93c18902Thanks @imkunet! - This patch allows Shiki to use all of its reserved languages instead of the previous behavior of forcing unknown languages to plaintext.
- #10494
19e42c368184013fc30d1e46753b9e9383bb2bdfThanks @bluwy! - Fixes support for Shiki transformers that access themetato conditionally perform transformations
-
#9960
c081adf998d30419fed97d8fccc11340cdc512e0Thanks @StandardGage! - Allows passing any props to the<Code />component -
#10130
5a9528741fa98d017b269c7e4f013058028bdc5dThanks @bluwy! - Migratesshikijitoshiki1.0 -
#10104
a31bbd7ff8f3ec62ee507f72d1d25140b82ffc18Thanks @remcohaszing! - Changes Astro's internal syntax highlighting to use rehype plugins instead of remark plugins. This provides better interoperability with other rehype plugins that deal with code blocks, in particular with third party syntax highlighting plugins andrehype-mermaid.This may be a breaking change if you are currently using:
- a remark plugin that relies on nodes of type
html - a rehype plugin that depends on nodes of type
raw.
Please review your rendered code samples carefully, and if necessary, consider using a rehype plugin that deals with the generated
elementnodes instead. You can transform the AST of raw HTML strings, or alternatively usehast-util-to-htmlto get a string from arawnode. - a remark plugin that relies on nodes of type
- #9866
44c957f893c6bf5f5b7c78301de7b21c5975584dThanks @ktym4a! - Fixes a bug where non-UTF-8 file names are not displayed when using relative paths in markdowns.
- #9738
a505190933365268d48139a5f197a3cfb5570870Thanks @bluwy! - Fixes usage in browser environments by using subpath imports
-
#9736
53c69dcc82cdf4000aff13a6c11fffe19096cf45Thanks @bluwy! - Initializes internalcwdUrlStrvariable lazily for performance, and workaround Rollup side-effect detection bug when building for non-Node runtimes -
#9723
2f81cffa9da9db0e2802d303f94feaee8d2f54ecThanks @blackmann! - Fixes a case where transformers wouldn't work on theclassproperty
-
#9566
165cfc154be477337037185c32b308616d1ed6faThanks @OliverSpeir! - Allows remark plugins to pass options specifying how images in.mdfiles will be optimized -
#9643
e9a72d9a91a3741566866bcaab11172cb0dc7d31Thanks @blackmann! - Adds a newmarkdown.shikiConfig.transformersconfig option. You can use this option to transform the Shikiji hast (AST format of the generated HTML) to customize the final HTML. Also updates Shikiji to the latest stable version.See Shikiji's documentation for more details about creating your own custom transformers, and a list of common transformers you can add directly to your project.
- #9349
270c6cc27Thanks @lilnasy! - Fixes an issue where this package could not be installed alongside Astro 4.0.
-
#9138
abf601233Thanks @bluwy! - Updates the unified, remark, and rehype dependencies to latest. Make sure to update your custom remark and rehype plugins as well to be compatible with the latest versions.Potentially breaking change: The default value of
markdown.remarkRehype.footnoteBackLabelis changed from"Back to content"to"Back to reference 1". See themdast-util-to-hastcommit for more information. -
#9182
c7953645eThanks @bluwy! - Removes deprecated APIs. All Astro packages had been refactored to not use these APIs.
-
#9138
abf601233Thanks @bluwy! - Updates the unified, remark, and rehype dependencies to latest. Make sure to update your custom remark and rehype plugins as well to be compatible with the latest versions.Potentially breaking change: The default value of
markdown.remarkRehype.footnoteBackLabelis changed from"Back to content"to"Back to reference 1". See themdast-util-to-hastcommit for more information. -
#9182
c7953645eThanks @bluwy! - Removes deprecated APIs. All Astro packages had been refactored to not use these APIs.
-
#9147
addb57c8eThanks @bluwy! - FixesRemarkRehypetype'shandlerandhandlersproperties -
Updated dependencies [
abf601233,6201bbe96,cdabf6ef0,1c48ed286,37697a2c5,bd0c2e9ae,0fe3a7ed5,710be505c,153a5abb9]:- astro@4.0.0-beta.0
- #9083
4537ecf0dThanks @bluwy! - ExportscreateShikiHighlighterfor low-level syntax highlighting usage
- #8903
c5010aad3Thanks @horo-fox! - Adds experimental support for multiple shiki themes with the newmarkdown.shikiConfig.experimentalThemesoption.
-
#8502
c4270e476Thanks @bluwy! - Updates the internalshikisyntax highlighter toshikiji, an ESM-focused alternative that simplifies bundling and maintenance.There are no new options and no changes to how you author code blocks and syntax highlighting.
Potentially breaking change: While this refactor should be transparent for most projects, the transition to
shikijinow produces a smaller HTML markup by attaching a fallbackcolorstyle to thepreorcodeelement, instead of to the linespandirectly. For example:Before:
<code class="astro-code" style="background-color: #24292e"> <pre> <span class="line" style="color: #e1e4e8">my code</span> </pre> </code>
After:
<code class="astro-code" style="background-color: #24292e; color: #e1e4e8"> <pre> <span class="line">my code<span> </pre> </code>
This does not affect the colors as the
spanwill inherit thecolorfrom the parent, but if you're relying on a specific HTML markup, please check your site carefully after upgrading to verify the styles.
- Updated dependencies [
2993055be,c4270e476,bd5aa1cd3,f369fa250,391729686,f999365b8,b2ae9ee0c,0abff97fe,3bef32f81]:- astro@3.3.0
-
#8715
21f482657Thanks @cprass! - Removeis:rawfrom remark Shiki plugin -
#8737
6f60da805Thanks @ematipico! - Add provenance statement when publishing the library from CI -
Updated dependencies [
6f60da805,d78806dfe,d1c75fe15,aa265d730,78adbc443,21e0757ea,357270f2a]:- astro@3.2.3
-
#8475
d93987824Thanks @webpro! - feat(markdown): Add support forimageReferencepaths when collecting images -
#8532
7522bb491Thanks @bluwy! - ExportcreateMarkdownProcessorand deprecaterenderMarkdownAPI
- Updated dependencies [
7522bb491,ecc65abbf,2c4fc878b,c92e0acd7,f95febf96,b85c8a78a,45364c345]:- astro@3.1.0
-
#8179
6011d52d3Thanks @matthewp! - Astro 3.0 Release Candidate -
#8169
e79e3779dThanks @bluwy! - Remove pre-shiki v0.14 theme names for compatibility. Please rename to the new theme names to migrate:material-darker->material-theme-darkermaterial-default->material-themematerial-lighter->material-theme-lightermaterial-ocean->material-theme-oceanmaterial-palenight->material-theme-palenight
- Updated dependencies [
d0679a666,db39206cb,adf9fccfd,0c7b42dc6,46c4c0e05,364d861bd,2484dc408,81545197a,6011d52d3,c2c71d90c,cd2d7e769,80f1494cd,e45f30293,c0de7a7b0,65c354969,3c3100851,34cb20021,a824863ab,44f7a2872,1048aca55,be6bbd2c8,9e021a91c,7511a4980,c37632a20,acf652fc1,42785c7b7,8450379db,dbc97b121,7d2f311d4,2540feedb,ea7ff5177,68efd4a8b,7bd1b86f8,036388f66,519a1c4e8,1f58a7a1b,2ae9d37f0,a8f35777e,70f34f5a3,5208a3c8f,84af8ed9d,f003e7364,ffc9e2d3d,732111cdc,0f637c71e,33b8910cf,8a5b0c1f3,148e61d24,e79e3779d,632579dc2,3674584e0,1db4e92c1,e7f872e91,16f09dfff,4477bb41c,55c10d1d5,3e834293d,96beb883a,997a0db8a,80f1494cd,0f0625504,e1ae56e72,f32d093a2,f01eb585e,b76c166bd,a87cbe400,866ed4098,767eb6866,32669cd47]:- @astrojs/prism@3.0.0
- astro@3.0.0
-
#8179
6011d52d3Thanks @matthewp! - Astro 3.0 Release Candidate -
#8169
e79e3779dThanks @bluwy! - Remove pre-shiki v0.14 theme names for compatibility. Please rename to the new theme names to migrate:material-darker->material-theme-darkermaterial-default->material-themematerial-lighter->material-theme-lightermaterial-ocean->material-theme-oceanmaterial-palenight->material-theme-palenight
- Updated dependencies [
adf9fccfd,582132328,81545197a,6011d52d3,be6bbd2c8,42785c7b7,95120efbe,2ae9d37f0,f003e7364,732111cdc,33b8910cf,e79e3779d,179796405,a87cbe400,767eb6866]:- astro@3.0.0-rc.5
- @astrojs/prism@3.0.0-rc.1
- Updated dependencies [
1eae2e3f7,76ddef19c,9b4f70a62,3fdf509b2,2f951cd40,c022a4217,67becaa58,bc37331d8,dfc2d93e3,3dc1ca2fa,1be84dfee,35f01df79,3fdf509b2,78de801f2,59d6e569f,7723c4cc9,fb5cd6b56,631b9c410]:- @astrojs/prism@3.0.0-beta.0
- astro@3.0.0-beta.0
-
#7104
826e02890Thanks @bluwy! - Specify"files"field to only publish necessary files -
Updated dependencies [
4516d7b22,e186ecc5e,c6d7ebefd,914c439bc,e9fc2c221,075eee08f,719002ca5,fc52681ba,fb84622af,cada10a46,cd410c5eb,73ec6f6c1,410428672,763ff2d1e,c1669c001,3d525efc9,826e02890]:- astro@2.5.0
- @astrojs/prism@2.1.2
- #6932
49514e4ceThanks @bluwy! - Upgrade shiki to v0.14.1. This updates the shiki theme colors and adds the theme name to thepretag, e.g.<pre class="astro-code github-dark">.
- Updated dependencies [
818252acd,80e3d4d3d,3326492b9,cac4a321e,831b67cdb,49514e4ce,0883fd487]:- astro@2.4.0
-
#6824
2511d58d5Thanks @Princesseuh! - Add support for using optimized and relative images in MDX files withexperimental.assets -
Updated dependencies [
8539eb164,a9c22994e,948a6d7be]:- astro@2.3.0
-
#6744
a1a4f45b5Thanks @Princesseuh! - Fix remote images in Markdown throwing errors when usingexperimental.assets -
Updated dependencies [
489dd8d69,a1a4f45b5,a1108e037,8b88e4cf1,d54cbe413,4c347ab51,ff0430786,2f2e572e9,7116c021a]:- astro@2.2.0
-
#6604
7f7a8504bThanks @Princesseuh! - Fix using optimized images in Markdown not working -
Updated dependencies [
7f7a8504b,38e6ec21e,f42f47dc6]:- astro@2.1.5
-
#6559
90e5f87d0Thanks @Princesseuh! - Vendorimage-sizeto fix CJS-related issues -
#6555
f5fddafc2Thanks @Princesseuh! - Add avalidateOptionshook to the Image Service API in order to set default options and validate the passed options -
Updated dependencies [
04dddd783,ea9b3dd72,bf024cb34,22955b895,f413446a8,90e5f87d0,388190102,035c0c4df,f112c12b1,689884251,fa132e35c,f5fddafc2,283734525,66858f1f2,6c465e958]:- astro@2.1.4
-
#6344
694918a56Thanks @Princesseuh! - Add a new experimental flag (experimental.assets) to enable our new core Assets story.This unlocks a few features:
- A new built-in image component and JavaScript API to transform and optimize images.
- Relative images with automatic optimization in Markdown.
- Support for validating assets using content collections.
- and more!
See Assets (Experimental) on our docs site for more information on how to use this feature!
-
#6213
afbbc4d5bThanks @Princesseuh! - Updated compilation settings to disable downlevelling for Node 14
- Updated dependencies [
fec583909,b087b83fe,694918a56,a20610609,a4a74ab70,75921b3cd,afbbc4d5b]:- astro@2.1.0
- @astrojs/prism@2.1.0
-
#5978
7abb1e905Thanks @HiDeoo! - Fix MDX heading IDs generation when using a frontmatter reference -
Updated dependencies [
b53e0717b,60b32d585,883e0cc29,dabce6b8c,aedf23f85]:- astro@2.0.2
-
#5687
e2019be6fThanks @bholmesdev! - Give remark and rehype plugins access to user frontmatter via frontmatter injection. This meansdata.astro.frontmatteris now the complete Markdown or MDX document's frontmatter, rather than an empty object.This allows plugin authors to modify existing frontmatter, or compute new properties based on other properties. For example, say you want to compute a full image URL based on an
imageSrcslug in your document frontmatter:export function remarkInjectSocialImagePlugin() { return function (tree, file) { const { frontmatter } = file.data.astro; frontmatter.socialImageSrc = new URL(frontmatter.imageSrc, 'https://my-blog.com/').pathname; }; }
When using Content Collections, you can access this modified frontmatter using the
remarkPluginFrontmatterproperty returned when rendering an entry.Migration instructions
Plugin authors should now check for user frontmatter when applying defaults.
For example, say a remark plugin wants to apply a default
titleif none is present. Add a conditional to check if the property is present, and update if none exists:export function remarkInjectTitlePlugin() { return function (tree, file) { const { frontmatter } = file.data.astro; + if (!frontmatter.title) { frontmatter.title = 'Default title'; + } } }This differs from previous behavior, where a Markdown file's frontmatter would always override frontmatter injected via remark or rehype.
-
#5785
16107b6a1Thanks @delucis! - Drop support for legacy Astro-flavored Markdown -
#5684
a9c292026& #576993e633922Thanks @bholmesdev! - Refine Markdown and MDX configuration options for ease-of-use.-
Markdown
-
Replace the
extendDefaultPluginsoption with agfmboolean and asmartypantsboolean. These are enabled by default, and can be disabled to remove GitHub-Flavored Markdown and SmartyPants. -
Ensure GitHub-Flavored Markdown and SmartyPants are applied whether or not custom
remarkPluginsorrehypePluginsare configured. If you want to apply custom plugins and remove Astro's default plugins, manually setgfm: falseandsmartypants: falsein your config.
-
-
Migrate
extendDefaultPluginstogfmandsmartypantsYou may have disabled Astro's built-in plugins (GitHub-Flavored Markdown and Smartypants) with the
extendDefaultPluginsoption. This has now been split into 2 flags to disable each plugin individually:markdown.gfmto disable GitHub-Flavored Markdownmarkdown.smartypantsto disable SmartyPants
// astro.config.mjs import { defineConfig } from 'astro/config'; export default defineConfig({ markdown: { - extendDefaultPlugins: false, + smartypants: false, + gfm: false, } });Additionally, applying remark and rehype plugins no longer disables
gfmandsmartypants. You will need to opt-out manually by settinggfmandsmartypantstofalse. -
MDX
-
Support all Markdown configuration options (except
drafts) from your MDX integration config. This includessyntaxHighlightingandshikiConfigoptions to further customize the MDX renderer. -
Simplify
extendPluginsto anextendMarkdownConfigoption. MDX options will default to their equivalent in your Markdown config. By settingextendMarkdownConfigto false, you can "eject" to set your own syntax highlighting, plugins, and more.
-
-
Migrate MDX's
extendPluginstoextendMarkdownConfigYou may have used the
extendPluginsoption to manage plugin defaults in MDX. This has been replaced by 3 flags:extendMarkdownConfig(trueby default) to toggle Markdown config inheritance. This replaces theextendPlugins: 'markdown'option.gfm(trueby default) andsmartypants(trueby default) to toggle GitHub-Flavored Markdown and SmartyPants in MDX. This replaces theextendPlugins: 'defaults'option.
-
-
#5825
52209ca2aThanks @bholmesdev! - Baseline the experimentalcontentCollectionsflag. You're free to remove this from your astro config!import { defineConfig } from 'astro/config'; export default defineConfig({ - experimental: { contentCollections: true } }) -
#5806
7572f7402Thanks @matthewp! - Make astro apeerDependencyof integrationsThis marks
astroas apeerDependencyof several packages that are already gettingmajorversion bumps. This is so we can more properly track the dependency between them and what version of Astro they are being used with.
Patch Changes
-
#5837
12f65a4d5Thanks @giuseppelt! - fix shiki css class replace logic -
Updated dependencies [
93e633922,16dc36a87,01f3f463b,e2019be6f,05caf445d,49ab4f231,a342a486c,8fb28648f,1f92d64ea,c2180746b,ae8a012a7,cf2de5422,ce5c5dbd4,ec09bb664,665a2c222,259a539d7,f7aa1ec25,4987d6f44,304823811,302e0ef8f,55cea0a9d,dd56c1941,9963c6e4d,be901dc98,f6cf92b48,e818cc046,8c100a6fe,116d8835c,840412128,1f49cddf9,7325df412,16c7d0bfd,a9c292026,2a5786419,4a1cabfe6,a8d3e7924,fa8c131f8,64b8082e7,c4b0cb8bf,23dc9ea96,63a6ceb38,a3a7fc929,52209ca2a,5fd9208d4,5eba34fcc,899214298,3a00ecb3e,5eba34fcc,2303f9514,1ca81c16b,b66d7195c]:- astro@2.0.0
- @astrojs/prism@2.0.0
See changes in 2.0.0-beta.2
-
#5785
16107b6a1Thanks @delucis! - Drop support for legacy Astro-flavored Markdown -
#5825
52209ca2aThanks @bholmesdev! - Baseline the experimentalcontentCollectionsflag. You're free to remove this from your astro config!import { defineConfig } from 'astro/config'; export default defineConfig({ - experimental: { contentCollections: true } }) -
#5806
7572f7402Thanks @matthewp! - Make astro a peerDependency of integrationsThis marks
astroas a peerDependency of several packages that are already gettingmajorversion bumps. This is so we can more properly track the dependency between them and what version of Astro they are being used with.
-
#5837
12f65a4d5Thanks @giuseppelt! - fix shiki css class replace logic -
Updated dependencies [
01f3f463b,1f92d64ea,c2180746b,ae8a012a7,cf2de5422,ec09bb664,665a2c222,f7aa1ec25,302e0ef8f,840412128,1f49cddf9,4a1cabfe6,c4b0cb8bf,23dc9ea96,63a6ceb38,52209ca2a,2303f9514]:- astro@2.0.0-beta.2
- @astrojs/prism@2.0.0-beta.0
See changes in 2.0.0-beta.1
-
#5769
93e633922Thanks @bholmesdev! - Introduce asmartypantsflag to opt-out of Astro's default SmartyPants plugin.{ markdown: { smartypants: false, } }
You may have disabled Astro's built-in plugins (GitHub-Flavored Markdown and Smartypants) with the
extendDefaultPluginsoption. This has now been split into 2 flags to disable each plugin individually:markdown.gfmto disable GitHub-Flavored Markdownmarkdown.smartypantsto disable SmartyPants
// astro.config.mjs import { defineConfig } from 'astro/config'; export default defineConfig({ markdown: { - extendDefaultPlugins: false, + smartypants: false, + gfm: false, } });
See changes in 2.0.0-beta.0
-
#5687
e2019be6fThanks @bholmesdev! - Give remark and rehype plugins access to user frontmatter via frontmatter injection. This meansdata.astro.frontmatteris now the complete Markdown or MDX document's frontmatter, rather than an empty object.This allows plugin authors to modify existing frontmatter, or compute new properties based on other properties. For example, say you want to compute a full image URL based on an
imageSrcslug in your document frontmatter:export function remarkInjectSocialImagePlugin() { return function (tree, file) { const { frontmatter } = file.data.astro; frontmatter.socialImageSrc = new URL(frontmatter.imageSrc, 'https://my-blog.com/').pathname; }; }
We have changed inject frontmatter to modify frontmatter in our docs to improve discoverability. This is based on support forum feedback, where "injection" is rarely the term used.
To reflect this, the
injectedFrontmatterproperty has been renamed toremarkPluginFrontmatter. This should clarify this plugin is still separate from thedataexport Content Collections expose today.Plugin authors should now check for user frontmatter when applying defaults.
For example, say a remark plugin wants to apply a default
titleif none is present. Add a conditional to check if the property is present, and update if none exists:export function remarkInjectTitlePlugin() { return function (tree, file) { const { frontmatter } = file.data.astro; + if (!frontmatter.title) { frontmatter.title = 'Default title'; + } } }This differs from previous behavior, where a Markdown file's frontmatter would always override frontmatter injected via remark or rehype.
-
#5684
a9c292026Thanks @bholmesdev! - Refine Markdown and MDX configuration options for ease-of-use.- Remove
remark-smartypantsfrom Astro's default Markdown plugins. - Replace the
extendDefaultPluginsoption with a simplifiedgfmboolean. This is enabled by default, and can be disabled to remove GitHub-Flavored Markdown. - Ensure GitHub-Flavored Markdown is applied whether or not custom
remarkPluginsorrehypePluginsare configured. If you want to apply custom plugins and remove GFM, manually setgfm: falsein your config.
- Support all Markdown configuration options (except
drafts) from your MDX integration config. This includessyntaxHighlightingandshikiConfigoptions to further customize the MDX renderer. - Simplify
extendDefaultsto anextendMarkdownConfigoption. MDX options will default to their equivalent in your Markdown config. By settingextendMarkdownConfigto false, you can "eject" to set your own syntax highlighting, plugins, and more.
To preserve your existing Markdown and MDX setup, you may need some configuration changes:
Smartypants has been removed from Astro's default setup. If you rely on this plugin, install
remark-smartypantsand apply to yourastro.config.*:// astro.config.mjs import { defineConfig } from 'astro/config'; + import smartypants from 'remark-smartypants'; export default defineConfig({ markdown: { + remarkPlugins: [smartypants], } });You may have disabled Astro's built-in plugins (GitHub-Flavored Markdown and Smartypants) with the
extendDefaultPluginsoption. Since Smartypants has been removed, this has been renamed togfm.// astro.config.mjs import { defineConfig } from 'astro/config'; export default defineConfig({ markdown: { - extendDefaultPlugins: false, + gfm: false, } });Additionally, applying remark and rehype plugins no longer disables
gfm. You will need to opt-out manually by settinggfmtofalse.You may have used the
extendPluginsoption to manage plugin defaults in MDX. This has been replaced by 2 flags:extendMarkdownConfig(trueby default) to toggle Markdown config inheritance. This replaces theextendPlugins: 'markdown'option.gfm(trueby default) to toggle GitHub-Flavored Markdown in MDX. This replaces theextendPlugins: 'defaults'option.
- Remove
-
#5654
2c65b433bThanks @delucis! - Refactor and exportrehypeHeadingIdspluginThe
rehypeHeadingIdsplugin injects IDs for all headings in a Markdown document and can now also handle MDX inputs if needed. You can import and use this plugin if you need heading IDs to be injected before other rehype plugins run.
- #5648
853081d1cThanks @bholmesdev! - Prevent relative image paths insrc/content/
-
#4842
812658ad2Thanks @bluwy! - Fix non-hoisted remark/rehype plugin loading -
#4842
812658ad2Thanks @bluwy! - Add missing dependencies, support strict dependency installation (e.g. pnpm)
- #4474
ac0321824Thanks @bholmesdev! - Add "extends" to markdown plugin config to preserve Astro defaults
- #4474
ac0321824Thanks @bholmesdev! - Add "extends" to markdown plugin config to preserve Astro defaults
-
04ad44563- > Astro v1.0 is out! Read the official announcement post.No breaking changes. This package is now officially stable and compatible with
astro@1.0.0!
- Updated dependencies [
04ad44563]:- @astrojs/prism@1.0.0
- #4176
2675b8633Thanks @bholmesdev! - Support frontmatter injection for MD and MDX using remark and rehype plugins
- #4137
471c6f784Thanks @bholmesdev! - Speed up internal markdown builds with new vite-plugin markdown
- #4169
16034f0ddThanks @hippotastic! - Fix double-escaping of non-highlighted code blocks in Astro-flavored markdown
- #4114
64432bcb8Thanks @Princesseuh! - Refactor@astrojs/mdxand@astrojs/markdown-remarkto use@astrojs/prisminstead of duplicating the code
- Updated dependencies [
64432bcb8]:- @astrojs/prism@0.7.0
ba11b3399Thanks @RafidMuhymin! - fixed generated slugs in markdown that ends with a dash
-
#4016
00fab4ce1Thanks @bholmesdev! - The use of components and JSX expressions in Markdown are no longer supported by default.For long term support, migrate to the
@astrojs/mdxintegration for MDX support (including.mdxpages!).Not ready to migrate to MDX? Add the legacy flag to your Astro config to re-enable the previous Markdown support.
// https://astro.build/config export default defineConfig({ legacy: { astroFlavoredMarkdown: true, }, });
- #4031
6e27a5fdcThanks @natemoo-re! - BREAKING Renamed Markdown utility functiongetHeaders()togetHeadings().
- #4008
399d7e269Thanks @bholmesdev! - Avoid parsing JSX, components, and Astro islands when using "plain" md mode. This bringsmarkdown.mode: 'md'in-line with our docs description.
- #3924
07fb544daThanks @FredKSchott! - Remove unused ssr-utils file
- Updated dependencies [
31f9c0bf0]:- @astrojs/prism@0.6.1
- #3919
01a55467dThanks @FredKSchott! - Add back missing ssr-utils.js file
-
#3911
ca45c0c27Thanks @JuanM04! - Don't throw when Shiki doesn't recognize a language -
Updated dependencies [
b48767985]:- @astrojs/prism@0.6.0
- #3669
93e1020b1Thanks @natemoo-re! - Tooling: reintroduce smoke test across example projects
- Updated dependencies [
1cc5b7890]:- @astrojs/prism@0.5.0
- #3638
80c71c7cThanks @tony-sull! - Fix: HTML comments in markdown code blocks should not be wrapped in JS comments
- #3612
fca58cfdThanks @bholmesdev! - Fix: "vpath" import error when building for netlify edge
- #3630
48e67fe0Thanks @tony-sull! - Encodes ampersand characters in code blocks
- #3620
05aa7244Thanks @hippotastic! - Remove extra newlines around Markdown components
- #3572
5c73f614Thanks @hippotastic! - Fix remarkMdxish performance issue on huge sites
- #3564
76fb01cfThanks @hippotastic! - Fix autolinking of URLs inside links
- #3554
c549f161Thanks @hippotastic! - Allow AlpineJS syntax extensions in Markdown
- #3514
6c955ca6Thanks @hippotastic! - Fix Markdown errors missing source filename
- #3516
30578015Thanks @hippotastic! - Fix: Allow self-closing tags in Markdown
- #3486
119ecf8dThanks @hippotastic! - Fix components in markdown regressions
- #3444
51db2b9bThanks @bholmesdev! - Fix: markdown imports failing due to internal dependency issue
- #3410
cfae9760Thanks @natemoo-re! - Significantly more stable behavior for "Markdown + Components" usage, which now handles component serialization much more similarly to MDX. Also supports switching between Components and Markdown without extra newlines, removes wrapping<p>tags from standalone components, and improves JSX expression handling.
- #3234
de123b28Thanks @JuanM04! - Removedrehype-slugin favor of our own implementation. The behavior of the slugging should remain the same
- #3152
9ba1f4f8Thanks @bholmesdev! - Fix JSX expression inconsistencies within markdown files
- #3108
ef198ff8Thanks @FredKSchott! - shiki: Adddiffsymbol handling to disableuser-selecton+/-symbols.
53162534Thanks @FredKSchott! - - RemovedrenderMarkdownWithFrontmatterbecause it wasn't being used- All options of
renderMarkdownare now required — see the exported interfaceAstroMarkdownOptions - New types: RemarkPlugin, RehypePlugin and ShikiConfig
- All options of
e425f896Thanks @FredKSchott! - Update config options to respect RFC0019
- #2824
0a3d3e51Thanks @bholmesdev! - Change shiki to our default markdown syntax highlighter. This includes updates to all relevant starter projects that used Prism-specific styles.
-
#2870
d763ec18Thanks @FredKSchott! - Fix a shiki performance issue affecting large sites -
Updated dependencies [
2db97f10]:- @astrojs/prism@0.4.1
-
#2870
d763ec18Thanks @FredKSchott! - Fix a shiki performance issue affecting large sites -
Updated dependencies [
2db97f10]:- @astrojs/prism@0.4.1-next.0
- #2824
0a3d3e51Thanks @bholmesdev! - Change shiki to our default markdown syntax highlighter. This includes updates to all relevant starter projects that used Prism-specific styles.
- #2697
91765d79Thanks @FredKSchott! - Improve performance by optimizing calls togetHighlighter
- #2534
cfeaa941Thanks @JuanM04! - Now you can use local plugins by passing a function instead of animport
- #2518
2bc91543Thanks @JuanM04! - Added the ability to use custom themes and langs with Shiki (<Code />and@astrojs/markdown-remark)
- #2534
cfeaa941Thanks @JuanM04! - Now you can use local plugins by passing a function instead of animport
- #2518
2bc91543Thanks @JuanM04! - Added the ability to use custom themes and langs with Shiki (<Code />and@astrojs/markdown-remark)
- #2202
45cea6aeThanks @jonathantneal! - Officially drop support for Node v12. The minimum supported version is now Node v14.15+,
- Updated dependencies [
45cea6ae]:- @astrojs/prism@0.4.0
- 679d4395: - Upgraded dependencies
- Replaced
remark-slugwithrehype-slugbecause it was deprecated - Replaced
@silvenon/remark-smartypantswithremark-smartypantsbecause its name was changed - Disable all built-in plugins when custom remark and/or rehype plugins are added
- Removed
remark-footnotesbecauseremark-gfmnow supports footnotes - Re-added
remark-smartypantsandrehype-slugto the default plugins list
- Replaced
- e6aaeff5: Initial release.
- Updated dependencies [e6aaeff5]
- @astrojs/prism@0.3.0
- 00d2b625: Move gray-matter to deps
- 7eaabbb0: Fix bug where code blocks would not be escaped properly
- d84bfe71: Adds prism support within the Markdown plugin.
- Updated dependencies [d84bfe71]
- @astrojs/prism@0.3.0-next.0
- b03f8771: Fix parsing of an empty
<pre></pre>tag in markdown files, which expected the pre tag to have a child - b03f8771: Fix the importing of
unifiedPluginandUnifiedPlugintypes
- 397d8f3d: Upgrade
@astrojs/markdown-supportdependencies. Theremark-rehype@9upgrade enables accessible footnotes withremark-footnotes.
- a421329f: Fix the left-brace issue
- 460e625: Move remaining missing dependencies
- 7015356: Move rehype-raw to a dependency
- 70f0a09: Added remark-slug to default plugins
-
d396943: Add support for
remarkandrehypeplugins for both.mdpages and.astropages using the<Markdown>component.For example, the
astro.config.mjscould be updated to include the following. Read the Markdown documentation for more information.Note Enabling custom
remarkPluginsorrehypePluginsremoves Astro's built-in support for GitHub-flavored Markdown support, Footnotes syntax, Smartypants. You must explicitly add these plugins to yourastro.config.mjsfile, if desired.export default { markdownOptions: { remarkPlugins: ['remark-slug', ['remark-autolink-headings', { behavior: 'prepend' }]], rehypePlugins: ['rehype-slug', ['rehype-autolink-headings', { behavior: 'prepend' }]], }, };
- f83407e: Expose
htmltoAstro.fetchContent(#571)
- f9f2da4: Add repository key to all package.json
- 50e6f49: Fixes issues with using astro via the create script