AstroEco is Releasing…
Display your GitHub releases using astro-loader-github-releases

Patch Changes
-
#13647
ffbe8f2
Thanks @ascorbic! - Fixes a bug that caused a session error to be logged when using actions without sessions -
#13646
6744842
Thanks @florian-lefebvre! - Fixes a case where extra font sources were removed when using the experimental fonts API -
#13635
d75cac4
Thanks @florian-lefebvre! - The experimental fonts API now generates optimized fallbacks for every weight and style

Patch Changes
-
#13643
67b7493
Thanks @tanishqmanuja! - Fixes a case where the font facesrc
format would be invalid when using the experimental fonts API -
#13639
23410c6
Thanks @florian-lefebvre! - Fixes a case where some font families would not be downloaded when using the same font provider several times, using the experimental fonts API
Patch Changes
- #3132
5959919
Thanks @HiDeoo! - Fixes an issue where all border styles were not reset by the Starlight’s Tailwind compatibility package like in Tailwind base styles.

Patch Changes
- #13636
a9fd03f
Thanks @sarah11918! - Updates the wording for choosing the "minimal" starter template options

Patch Changes
-
#13632
cb05cfb
Thanks @florian-lefebvre! - Improves the optimized fallback name generated by the experimental Fonts API -
#13630
3e7db4f
Thanks @florian-lefebvre! - Fixes a case where fonts using a local provider would not work because of an invalid generatedsrc
-
#13634
516de7d
Thanks @ematipico! - Fixes a regression where usingnext('/')
didn't correctly return the requested route. -
#13632
cb05cfb
Thanks @florian-lefebvre! - Improves the quality of optimized fallbacks generated by the experimental Fonts API -
#13616
d475afc
Thanks @lfilho! - Fixes a regression where relative static redirects didn't work as expected.
Major Changes
-
#2322
f14eb0c
Thanks @HiDeoo! -⚠️ BREAKING CHANGE: The minimum supported version of Starlight is now 0.34.0Please use the
@astrojs/upgrade
command to upgrade your project:npx @astrojs/upgrade
-
#2322
f14eb0c
Thanks @HiDeoo! - Adds support for Tailwind v4, drops support for Tailwind v3.⚠️ BREAKING CHANGE: Tailwind v3 is no longer supported. Tailwind v4 support in Astro is now provided using a Vite plugin and the Astro Tailwind integration is no longer required.-
Remove the Astro Tailwind integration. The Astro Tailwind integration is no longer required with Tailwind v4.
// astro.config.mjs import { defineConfig } from "astro/config"; import starlight from "@astrojs/starlight"; -import tailwind from "@astrojs/tailwind"; export default defineConfig({ integrations: [ starlight({ title: "Docs with Tailwind", customCss: ["./src/tailwind.css"], }), - tailwind({ applyBaseStyles: false }), ], });
-
Install Tailwind v4. Install the latest version of the
tailwindcss
and@tailwindcss/vite
packages.Use the
astro add tailwind
command to install and configure both packages:npx astro add tailwind
-
Update Tailwind base styles. Tailwind CSS base styles needs to be updated for Tailwind v4 and also to use Starlight Tailwind CSS.
/* src/tailwind.css */ -@tailwind base; -@tailwind components; -@tailwind utilities; +@layer base, starlight, theme, components, utilities; + +@import '@astrojs/starlight-tailwind'; +@import 'tailwindcss/theme.css' layer(theme); +@import 'tailwindcss/utilities.css' layer(utilities); + +@theme { + /* + Configure your Tailwind theme that will be used by Starlight. + https://starlight.astro.build/guides/css-and-tailwind/#styling-starlight-with-tailwind + */ +} + +/* +Add additional Tailwind styles to this file: +https://tailwindcss.com/docs/adding-custom-styles#using-custom-css +*/
-
Update Tailwind customizations. If you previously customized your Tailwind theme configuration in the
tailwind.config.mjs
file, such customizations are now defined through CSS using the@theme
block in your Tailwind base styles.-
Locate existing customizations in your
tailwind.config.mjs
file. The following example defines customizations for the accent colors, gray scale, and font families used by Starlight:// tailwind.config.mjs import starlightPlugin from '@astrojs/starlight-tailwind'; import colors from 'tailwindcss/colors'; /** @type {import('tailwindcss').Config} */ export default { content: ['./src/**/*.{astro,html,js,jsx,md,mdx,svelte,ts,tsx,vue}'], theme: { extend: { colors: { // Custom accent colors. accent: colors.fuchsia, // Custom gray scale. gray: colors.slate, }, fontFamily: { // Custom text font. sans: ['"Atkinson Hyperlegible"'], // Custom code font. mono: ['"IBM Plex Mono"'], }, }, }, plugins: [starlightPlugin()], };
-
The above customizations can be migrated to the new
@theme
block in the file containing your Tailwind base styles as follows:/* src/tailwind.css */ @layer base, starlight, theme, components, utilities; @import '@astrojs/starlight-tailwind'; @import 'tailwindcss/theme.css' layer(theme); @import 'tailwindcss/utilities.css' layer(utilities); @theme { /* Custom accent colors. */ --color-accent-50: var(--color-fuchsia-50); --color-accent-100: var(--color-fuchsia-100); --color-accent-200: var(--color-fuchsia-200); --color-accent-300: var(--color-fuchsia-300); --color-accent-400: var(--color-fuchsia-400); --color-accent-500: var(--color-fuchsia-500); --color-accent-600: var(--color-fuchsia-600); --color-accent-700: var(--color-fuchsia-700); --color-accent-800: var(--color-fuchsia-800); --color-accent-900: var(--color-fuchsia-900); --color-accent-950: var(--color-fuchsia-950); /* Custom gray scale. */ --color-gray-50: var(--color-slate-50); --color-gray-100: var(--color-slate-100); --color-gray-200: var(--color-slate-200); --color-gray-300: var(--color-slate-300); --color-gray-400: var(--color-slate-400); --color-gray-500: var(--color-slate-500); --color-gray-600: var(--color-slate-600); --color-gray-700: var(--color-slate-700); --color-gray-800: var(--color-slate-800); --color-gray-900: var(--color-slate-900); --color-gray-950: var(--color-slate-950); /* Custom text font. */ --font-sans: 'Atkinson Hyperlegible'; /* Custom code font. */ --font-mono: 'IBM Plex Mono'; }
-
We recommend checking your site’s appearance when upgrading to make sure there are no style regressions caused by this change.
For full details about upgrading from Tailwind v3 to v4, see the official upgrade guide.
-
Minor Changes
-
#2322
f14eb0c
Thanks @HiDeoo! - Groups all of Starlight's CSS declarations into a singlestarlight
cascade layer.This change allows for easier customization of Starlight's CSS as any custom unlayered CSS will override the default styles. If you are using cascade layers in your custom CSS, you can use the
@layer
CSS at-rule to define the order of precedence for different layers including the ones used by Starlight.We recommend checking your site’s appearance when upgrading to make sure there are no style regressions caused by this change.
-
#3122
3a087d8
Thanks @delucis! - Removes defaultattrs
andcontent
values from head entries parsed using Starlight’s schema.Previously when adding
head
metadata via frontmatter or user config, Starlight would automatically add values forattrs
andcontent
if not provided. Now, these properties are leftundefined
.This makes it simpler to add tags in route middleware for example as you no longer need to provide empty values for
attrs
andcontent
:head.push({ tag: 'style', content: 'div { color: red }' - attrs: {}, }); head.push({ tag: 'link', - content: '' attrs: { rel: 'me', href: 'https://example.com' }, });
This is mostly an internal API but if you are overriding Starlight’s
Head
component or processing head entries in some way, you may wish to double check your handling ofAstro.locals.starlightRoute.head
is compatible withattrs
andcontent
potentially beingundefined
. -
#3033
8c19678
Thanks @delucis! - Adds support for generating clickable anchor links for headings.By default, Starlight now renders an anchor link beside headings in Markdown and MDX content. A new
<AnchorHeading>
component is available to achieve the same thing in custom pages built using<StarlightPage>
.If you want to disable this new Markdown processing set the
markdown.headingLinks
option in your Starlight config tofalse
:starlight({ title: 'My docs', markdown: { headingLinks: false, }, }),
⚠️ BREAKING CHANGE: The minimum supported version of Astro is now v5.5.0.Please update Starlight and Astro together:
npx @astrojs/upgrade
-
#2322
f14eb0c
Thanks @HiDeoo! - Removes Shikicss-variables
theme fallback.⚠️ BREAKING CHANGE:Previously, Starlight used to automatically provide a fallback theme for Shiki, the default syntax highlighter built into Astro if the configured Shiki theme was not
github-dark
.This fallback was only relevant when the default Starlight code block renderer, Expressive Code, was disabled and Shiki was used. Starlight no longer provides this fallback.
If you were relying on this behavior, you now manually need to update your Astro configuration to use the Shiki
css-variables
theme to match the previous behavior.import { defineConfig } from 'astro/config'; export default defineConfig({ + markdown: { + shikiConfig: { + theme: 'css-variables', + }, + }, });
Additionally, you can use custom CSS to control the appearance of the code blocks. Here are the previously used CSS variables for the fallback theme:
:root { --astro-code-foreground: var(--sl-color-white); --astro-code-background: var(--sl-color-gray-6); --astro-code-token-constant: var(--sl-color-blue-high); --astro-code-token-string: var(--sl-color-green-high); --astro-code-token-comment: var(--sl-color-gray-2); --astro-code-token-keyword: var(--sl-color-purple-high); --astro-code-token-parameter: var(--sl-color-red-high); --astro-code-token-function: var(--sl-color-red-high); --astro-code-token-string-expression: var(--sl-color-green-high); --astro-code-token-punctuation: var(--sl-color-gray-2); --astro-code-token-link: var(--sl-color-blue-high); }
Patch Changes
Minor Changes
-
#3033
8c19678
Thanks @delucis! - Adds support for generating clickable anchor links for headings.By default, the Starlight Markdoc preset now includes a default
heading
node, which renders an anchor link beside headings in your Markdoc content.If you want to disable this new feature, pass
headingLinks: false
in your Markdoc config:export default defineMarkdocConfig({ // Disable the default heading anchor link support extends: [starlightMarkdoc({ headingLinks: false })], });
⚠️ BREAKING CHANGE: The minimum supported peer version of Starlight is now v0.34.0.Please update Starlight and the Starlight Markdoc preset together:
npx @astrojs/upgrade

Patch Changes
-
#13594
dc4a015
Thanks @florian-lefebvre! - Reduces the number of font files downloaded -
#13627
7f1a624
Thanks @florian-lefebvre! - Fixes a case where using the<Font />
component would throw a Rollup error during the build -
#13626
3838efe
Thanks @florian-lefebvre! - Updates fallback font generation to always read font files returned by font providers -
#13625
f1311d2
Thanks @florian-lefebvre! - Updates the<Font />
component so that preload links are generated before the style tag ifpreload
is passed -
#13622
a70d32a
Thanks @ascorbic! - Improve autocomplete for session keys

Minor Changes
-
#13527
2fd6a6b
Thanks @ascorbic! - The experimental session API introduced in Astro 5.1 is now stable and ready for production use.Sessions are used to store user state between requests for on-demand rendered pages. You can use them to store user data, such as authentication tokens, shopping cart contents, or any other data that needs to persist across requests:
--- export const prerender = false; // Not needed with 'server' output const cart = await Astro.session.get('cart'); --- <a href="/checkout">🛒 {cart?.length ?? 0} items</a>
Configuring session storage
Sessions require a storage driver to store the data. The Node, Cloudflare and Netlify adapters automatically configure a default driver for you, but other adapters currently require you to specify a custom storage driver in your configuration.
If you are using an adapter that doesn't have a default driver, or if you want to choose a different driver, you can configure it using the
session
configuration option:import { defineConfig } from 'astro/config'; import vercel from '@astrojs/vercel'; export default defineConfig({ adapter: vercel(), session: { driver: 'upstash', }, });
Using sessions
Sessions are available in on-demand rendered pages, API endpoints, actions and middleware.
In pages and components, you can access the session using
Astro.session
:--- const cart = await Astro.session.get('cart'); --- <a href="/checkout">🛒 {cart?.length ?? 0} items</a>
In endpoints, actions, and middleware, you can access the session using
context.session
:export async function GET(context) { const cart = await context.session.get('cart'); return Response.json({ cart }); }
If you attempt to access the session when there is no storage driver configured, or in a prerendered page, the session object will be
undefined
and an error will be logged in the console:--- export const prerender = true; const cart = await Astro.session?.get('cart'); // Logs an error. Astro.session is undefined ---
Upgrading from Experimental to Stable
If you were previously using the experimental API, please remove the
experimental.session
flag from your configuration:import { defineConfig } from 'astro/config'; import node from '@astrojs/node'; export default defineConfig({ adapter: node({ mode: "standalone", }), - experimental: { - session: true, - }, });
See the sessions guide for more information.
-
#12775
b1fe521
Thanks @florian-lefebvre! - Adds a new, experimental Fonts API to provide first-party support for fonts in Astro.This experimental feature allows you to use fonts from both your file system and several built-in supported providers (e.g. Google, Fontsource, Bunny) through a unified API. Keep your site performant thanks to sensible defaults and automatic optimizations including fallback font generation.
To enable this feature, configure an
experimental.fonts
object with one or more fonts:import { defineConfig, fontProviders } from "astro/config" export default defineConfig({ experimental: { fonts: [{ provider: fontProviders.google(), ` name: "Roboto", cssVariable: "--font-roboto", }] } })
Then, add a
<Font />
component and site-wide styling in your<head>
:--- import { Font } from 'astro:assets'; --- <Font cssVariable="--font-roboto" preload /> <style> body { font-family: var(--font-roboto); } </style>
Visit the experimental Fonts documentation for the full API, how to get started, and even how to build your own custom
AstroFontProvider
if we don't yet support your preferred font service.For a complete overview, and to give feedback on this experimental API, see the Fonts RFC and help shape its future.
-
#13560
df3fd54
Thanks @ematipico! - The virtual moduleastro:config
introduced behind a flag in v5.2.0 is no longer experimental and is available for general use.This virtual module exposes two sub-paths for type-safe, controlled access to your configuration:
astro:config/client
: exposes config information that is safe to expose to the client.astro:config/server
: exposes additional information that is safe to expose to the server, such as file and directory paths.
Access these in any file inside your project to import and use select values from your Astro config:
// src/utils.js import { trailingSlash } from 'astro:config/client'; function addForwardSlash(path) { if (trailingSlash === 'always') { return path.endsWith('/') ? path : path + '/'; } else { return path; } }
If you were previously using this feature, please remove the experimental flag from your Astro config:
// astro.config.mjs export default defineConfig({ - experimental: { - serializeConfig: true - } })
If you have been waiting for feature stabilization before using configuration imports, you can now do so.
Please see the
astro:config
reference for more about this feature. -
#13578
406501a
Thanks @stramel! - The SVG import feature introduced behind a flag in v5.0.0 is no longer experimental and is available for general use.This feature allows you to import SVG files directly into your Astro project as components and inline them into your HTML.
To use this feature, import an SVG file in your Astro project, passing any common SVG attributes to the imported component.
--- import Logo from './path/to/svg/file.svg'; --- <Logo width={64} height={64} fill="currentColor" />
If you have been waiting for stabilization before using the SVG Components feature, you can now do so.
If you were previously using this feature, please remove the experimental flag from your Astro config:
import { defineConfig } from 'astro' export default defineConfig({ - experimental: { - svg: true, - } })
Additionally, a few features that were available during the experimental stage were removed in a previous release. Please see the v5.6.0 changelog for details if you have not yet already updated your project code for the experimental feature accordingly.
Please see the SVG Components guide in docs for more about this feature.
Patch Changes
-
#13602
3213450
Thanks @natemoo-re! - Updates the Audit dev toolbar app to automatically stripdata-astro-source-file
anddata-astro-source-loc
attributes in dev mode. -
#13598
f5de51e
Thanks @dreyfus92! - Fix routing with base paths when trailingSlash is set to 'never'. This ensures requests to '/base' are correctly matched when the base path is set to '/base', without requiring a trailing slash. -
#13603
d038030
Thanks @sarah11918! - Adds the minimal starter template to the list ofcreate astro
optionsGood news if you're taking the introductory tutorial in docs, making a minimal reproduction, or just want to start a project with as little to rip out as possible. Astro's
minimal
(empty) template is now back as one of the options when runningcreate astro@latest
and starting a new project!

Minor Changes
-
#13527
2fd6a6b
Thanks @ascorbic! - The experimental session API introduced in Astro 5.1 is now stable and ready for production use.Sessions are used to store user state between requests for on-demand rendered pages. You can use them to store user data, such as authentication tokens, shopping cart contents, or any other data that needs to persist across requests:
--- export const prerender = false; // Not needed with 'server' output const cart = await Astro.session.get('cart'); --- <a href="/checkout">🛒 {cart?.length ?? 0} items</a>
Configuring session storage
Sessions require a storage driver to store the data. The Node, Cloudflare and Netlify adapters automatically configure a default driver for you, but other adapters currently require you to specify a custom storage driver in your configuration.
If you are using an adapter that doesn't have a default driver, or if you want to choose a different driver, you can configure it using the
session
configuration option:import { defineConfig } from 'astro/config'; import vercel from '@astrojs/vercel'; export default defineConfig({ adapter: vercel(), session: { driver: 'upstash', }, });
Using sessions
Sessions are available in on-demand rendered pages, API endpoints, actions and middleware.
In pages and components, you can access the session using
Astro.session
:--- const cart = await Astro.session.get('cart'); --- <a href="/checkout">🛒 {cart?.length ?? 0} items</a>
In endpoints, actions, and middleware, you can access the session using
context.session
:export async function GET(context) { const cart = await context.session.get('cart'); return Response.json({ cart }); }
If you attempt to access the session when there is no storage driver configured, or in a prerendered page, the session object will be
undefined
and an error will be logged in the console:--- export const prerender = true; const cart = await Astro.session?.get('cart'); // Logs an error. Astro.session is undefined ---
Upgrading from Experimental to Stable
If you were previously using the experimental API, please remove the
experimental.session
flag from your configuration:import { defineConfig } from 'astro/config'; import node from '@astrojs/node'; export default defineConfig({ adapter: node({ mode: "standalone", }), - experimental: { - session: true, - }, });
See the sessions guide for more information.

Minor Changes
-
#13527
2fd6a6b
Thanks @ascorbic! - The experimental session API introduced in Astro 5.1 is now stable and ready for production use.Sessions are used to store user state between requests for on-demand rendered pages. You can use them to store user data, such as authentication tokens, shopping cart contents, or any other data that needs to persist across requests:
--- export const prerender = false; // Not needed with 'server' output const cart = await Astro.session.get('cart'); --- <a href="/checkout">🛒 {cart?.length ?? 0} items</a>
Configuring session storage
Sessions require a storage driver to store the data. The Node, Cloudflare and Netlify adapters automatically configure a default driver for you, but other adapters currently require you to specify a custom storage driver in your configuration.
If you are using an adapter that doesn't have a default driver, or if you want to choose a different driver, you can configure it using the
session
configuration option:import { defineConfig } from 'astro/config'; import vercel from '@astrojs/vercel'; export default defineConfig({ adapter: vercel(), session: { driver: 'upstash', }, });
Using sessions
Sessions are available in on-demand rendered pages, API endpoints, actions and middleware.
In pages and components, you can access the session using
Astro.session
:--- const cart = await Astro.session.get('cart'); --- <a href="/checkout">🛒 {cart?.length ?? 0} items</a>
In endpoints, actions, and middleware, you can access the session using
context.session
:export async function GET(context) { const cart = await context.session.get('cart'); return Response.json({ cart }); }
If you attempt to access the session when there is no storage driver configured, or in a prerendered page, the session object will be
undefined
and an error will be logged in the console:--- export const prerender = true; const cart = await Astro.session?.get('cart'); // Logs an error. Astro.session is undefined ---
Upgrading from Experimental to Stable
If you were previously using the experimental API, please remove the
experimental.session
flag from your configuration:import { defineConfig } from 'astro/config'; import node from '@astrojs/node'; export default defineConfig({ adapter: node({ mode: "standalone", }), - experimental: { - session: true, - }, });
See the sessions guide for more information.
Patch Changes
- Updated dependencies []:
- @astrojs/underscore-redirects@0.6.0

Minor Changes
-
#13527
2fd6a6b
Thanks @ascorbic! - The experimental session API introduced in Astro 5.1 is now stable and ready for production use.Sessions are used to store user state between requests for on-demand rendered pages. You can use them to store user data, such as authentication tokens, shopping cart contents, or any other data that needs to persist across requests:
--- export const prerender = false; // Not needed with 'server' output const cart = await Astro.session.get('cart'); --- <a href="/checkout">🛒 {cart?.length ?? 0} items</a>
Configuring session storage
Sessions require a storage driver to store the data. The Node, Cloudflare and Netlify adapters automatically configure a default driver for you, but other adapters currently require you to specify a custom storage driver in your configuration.
If you are using an adapter that doesn't have a default driver, or if you want to choose a different driver, you can configure it using the
session
configuration option:import { defineConfig } from 'astro/config'; import vercel from '@astrojs/vercel'; export default defineConfig({ adapter: vercel(), session: { driver: 'upstash', }, });
Using sessions
Sessions are available in on-demand rendered pages, API endpoints, actions and middleware.
In pages and components, you can access the session using
Astro.session
:--- const cart = await Astro.session.get('cart'); --- <a href="/checkout">🛒 {cart?.length ?? 0} items</a>
In endpoints, actions, and middleware, you can access the session using
context.session
:export async function GET(context) { const cart = await context.session.get('cart'); return Response.json({ cart }); }
If you attempt to access the session when there is no storage driver configured, or in a prerendered page, the session object will be
undefined
and an error will be logged in the console:--- export const prerender = true; const cart = await Astro.session?.get('cart'); // Logs an error. Astro.session is undefined ---
Upgrading from Experimental to Stable
If you were previously using the experimental API, please remove the
experimental.session
flag from your configuration:import { defineConfig } from 'astro/config'; import node from '@astrojs/node'; export default defineConfig({ adapter: node({ mode: "standalone", }), - experimental: { - session: true, - }, });
See the sessions guide for more information.
Patch Changes
- Updated dependencies []:
- @astrojs/underscore-redirects@0.6.0

Minor Changes
-
#13578
406501a
Thanks @stramel! - The SVG import feature introduced behind a flag in v5.0.0 is no longer experimental and is available for general use.This feature allows you to import SVG files directly into your Astro project as components and inline them into your HTML.
To use this feature, import an SVG file in your Astro project, passing any common SVG attributes to the imported component.
--- import Logo from './path/to/svg/file.svg'; --- <Logo <Logo width={64} height={64} fill="currentColor" />
If you have been waiting for stabilization before using the SVG Components feature, you can now do so.
If you were previously using this feature, please remove the experimental flag from your Astro config:
import { defineConfig } from 'astro' export default defineConfig({ - experimental: { - svg: true, - } })
Additionally, a few features that were available during the experimental stage were removed in a previous release. Please see the v5.6.0 changelog for details if you have not yet already updated your project code for the experimental feature accordingly.
Please see the SVG Components guide in docs for more about this feature.

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version -
Updated dependencies [
3752519
,360cb91
]:- @astrojs/studio@0.1.7

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version -
Updated dependencies []:
- @astrojs/underscore-redirects@0.6.0

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version

Patch Changes
-
#13596
3752519
Thanks @jsparkdev! - update vite to latest version to fix CVE -
#13547
360cb91
Thanks @jsparkdev! - Updates vite to the latest version -
Updated dependencies []:
- @astrojs/underscore-redirects@0.6.0
Patch Changes
-
#3088
1885049
Thanks @HiDeoo! - Fixes a regression in Starlight version0.33.0
that caused the description and links to language alternates for multilingual websites to be missing from the<head>
of the page. -
#3065
463adf5
Thanks @HiDeoo! - Updates thesocial
configuration option TSDoc example to match the shape of the expected value.
Minor Changes
-
#3026
82deb84
Thanks @HiDeoo! - Fixes a potential list styling issue if the last element of a list item is a<script>
tag.⚠️ BREAKING CHANGE:This release drops official support for Chromium-based browsers prior to version 105 (released 30 August 2022) and Firefox-based browsers prior to version 121 (released 19 December 2023). You can find a list of currently supported browsers and their versions using this browserslist query.
With this release, Starlight-generated sites will still work fine on those older browsers except for this small detail in list item styling, but future releases may introduce further breaking changes for impacted browsers, including in patch releases.
-
#3025
f87e9ac
Thanks @delucis! - Makessocial
configuration more flexible.⚠️ BREAKING CHANGE: Thesocial
configuration option has changed syntax. You will need to update this inastro.config.mjs
when upgrading.Previously, a limited set of platforms were supported using a shorthand syntax with labels built in to Starlight. While convenient, this approach was less flexible and required dedicated code for each social platform added.
Now, you must specify the icon and label for each social link explicitly and you can use any of Starlight’s built-in icons for social links.
The following example shows updating the old
social
syntax to the new:- social: { - github: 'https://github.com/withastro/starlight', - discord: 'https://astro.build/chat', - }, + social: [ + { icon: 'github', label: 'GitHub', href: 'https://github.com/withastro/starlight' }, + { icon: 'discord', label: 'Discord', href: 'https://astro.build/chat' }, + ],
-
#2927
c46904c
Thanks @HiDeoo! - Adds thehead
route data property which contains an array of all tags to include in the<head>
of the current page.Previously, the
<Head>
component was responsible for generating a list of tags to include in the<head>
of the current page and rendering them.
This data is now available asAstro.locals.starlightRoute.head
instead and can be modified using route data middleware.
The<Head>
component now only renders the tags provided inAstro.locals.starlightRoute.head
. -
#2924
6a56d1b
Thanks @HiDeoo! -⚠️ BREAKING CHANGE: Ensures that the<Badge>
and<Icon>
components no longer render with a trailing space.In Astro, components that include styles render with a trailing space which can prevent some use cases from working as expected, e.g. when using such components inlined with text. This change ensures that the
<Badge>
and<Icon>
components no longer render with a trailing space.If you were previously relying on that implementation detail, you may need to update your code to account for this change. For example, considering the following code:
<Badge text="New" /> Feature
The rendered text would previously include a space between the badge and the text due to the trailing space automatically added by the component:
New Feature
Such code will now render the badge and text without a space:
NewFeature
To fix this, you can add a space between the badge and the text:
- <Badge text="New" />Feature + <Badge text="New" /> Feature
-
#2727
7c8fa30
Thanks @techfg! - Updates mobile menu toggle styles to display a close icon while the menu is open
Patch Changes
-
#2927
c46904c
Thanks @HiDeoo! - Fixes an issue where overriding the canonical URL of a page using thehead
configuration option orhead
frontmatter field would strip any other<link>
tags from the<head>
. -
#2927
c46904c
Thanks @HiDeoo! - Fixes an issue where generated canonical URLs would include a trailing slash when using thetrailingSlash
Astro option is set to'never'
. -
#3025
f87e9ac
Thanks @delucis! - Fixes Starlight’s autogenerated<meta name="twitter:site">
tags when a Twitter link is set insocial
config. Previously these incorrectly renderedcontent="/username"
and now correctly rendercontent="@username"
.
Patch Changes
-
#3030
5bdf139
Thanks @trueberryless! - Updates the type of theisFallback
field in route data fromtrue
toboolean
, keeping it optional but allowingfalse
as a possible value. -
#3018
188b8cf
Thanks @trueberryless! - Adds validation for user configrouteMiddleware
so it does not conflict with Astro's middleware.

Patch Changes
- Refactor first parameter type of exported
renderPostAsHtml
from PostView to RichTextProps (981ee1a
) - Update docs

Patch Changes
- #13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version

Patch Changes
- #13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version

Patch Changes
- #13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version

Patch Changes
- #13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version

Patch Changes
- #13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version

Patch Changes
- #13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version

Patch Changes
- #13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version

Patch Changes
-
#13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version -
Updated dependencies []:
- @astrojs/underscore-redirects@0.6.0

Minor Changes
-
#13514
a9aafec
Thanks @ascorbic! - Automatically configures Cloudflare KV storage when experimental sessions are enabledIf the
experimental.session
flag is enabled when using the Cloudflare adapter, Astro will automatically configure the session storage using the Cloudflare KV driver. You can still manually configure the session storage if you need to use a different driver or want to customize the session storage configuration. If you want to use sessions, you will need to create the KV namespace and declare it in your wrangler config. You can do this using the Wrangler CLI:npx wrangler kv namespace create SESSION
This will log the id of the created namespace. You can then add it to your
wrangler.json
/wrangler.toml
file like this:By default it uses the binding name
SESSION
, but if you want to use a different binding name you can do so by passing thesessionKVBindingName
option to the adapter. For example:import { defineConfig } from 'astro/config'; import cloudflare from '@astrojs/cloudflare'; export default defineConfig({ output: 'server', site: `http://example.com`, adapter: cloudflare({ platformProxy: { enabled: true, }, sessionKVBindingName: 'MY_SESSION', }), experimental: { session: true, }, });
See the Cloudflare KV docs for more details on setting up KV namespaces.
See the experimental session docs for more information on configuring session storage.
Patch Changes
-
#13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version -
Updated dependencies []:
- @astrojs/underscore-redirects@0.6.0

Patch Changes
- #13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version

Patch Changes
- #13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version

Patch Changes
-
#13526
ff9d69e
Thanks @jsparkdev! - updatevite
to the latest version -
Updated dependencies [
ff9d69e
]:- @astrojs/studio@0.1.6

🚨 Breaking Changes
- Install
remark-directive-sugar
while removing unneeded built-in plugins; update docs & deps - by @lin-stephanie (615c4)
🚀 Features
- page: Add
/shorts
page to share short notes or quick thoughts - by @lin-stephanie in #23 (a317c) - nav: Support
'hr'
innavBarLayout
option for custom dividers - by @lin-stephanie (76a78) - toc: Support
'content'
indisplayPosition
option to show TOC on hover over content ('.prose') - by @lin-stephanie (65447)
🐞 Bug Fixes
- Hide default marker for Safari compatibility - by @lin-stephanie (5a3f0)
- Update
Toc.astro
to support Chinese text anchor - by @infinitesum in #21 (753a1)
🏡 Chore
View changes on GitHub

Patch Changes
- Log missing tokens as
warn
instead oferror
. (0650a3d
)

Patch Changes
- Log missing tokens as
warn
instead oferror
. (0650a3d
)

Patch Changes
- #13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest.

Patch Changes
- #13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest.

Patch Changes
- #13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest.

Patch Changes
- #13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest.

Patch Changes
- #13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest.

Patch Changes
- #13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest.

Patch Changes
- #13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest.

Patch Changes
- #13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest.

Patch Changes
- #13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest.

Patch Changes
-
#13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest. -
Updated dependencies []:
- @astrojs/underscore-redirects@0.6.0

Patch Changes
-
#13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest. -
Updated dependencies []:
- @astrojs/underscore-redirects@0.6.0

Patch Changes
- #13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest.

Patch Changes
-
#13505
a98ae5b
Thanks @ematipico! - Updates the dependencyvite
to the latest. -
Updated dependencies [
a98ae5b
]:- @astrojs/studio@0.1.5


Minor Changes
-
#13444
9721f4a
Thanks @florian-lefebvre! - Adds globalastro:env
supportCloudflare workers now support importing
env
in the global scope. Until now, callingastro:env
APIs had to be done within request scope or the values wereundefined
.With this release, they can be called anywhere server-side, like any other official adapter.
Patch Changes



Patch Changes
- #2991
b8a4800
Thanks @florian-lefebvre! - Adds support for@astrojs/tailwind
v6

Minor Changes (bc7ccc0
)
- Consolidate consecutive newlines (
\n
) to single<br/ >\n
- Rename
urlTextType
option 'display-url' to 'post-text' - Fix schema for optional
description
inUserV2Schema

Minor Changes
-
#13352
cb886dc
Thanks @delucis! - Adds support for a newexperimental.headingIdCompat
flagBy 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
rehypeHeadingIds
plugin 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
a3327ff
Thanks @chrisirhc! - Adds a new configuration option for Markdown syntax highlightingexcludeLangs
This 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
mermaid
andmath
code 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.

Minor Changes
-
#13352
cb886dc
Thanks @delucis! - Adds support for a newexperimental.headingIdCompat
flagBy 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
rehypeHeadingIds
plugin 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, ], }, });
Patch Changes

Minor Changes
-
#13352
cb886dc
Thanks @delucis! - Adds support for a newexperimental.headingIdCompat
flagBy 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
rehypeHeadingIds
plugin 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, ], }, });
Patch Changes



Patch Changes
- Updated dependencies [
042d1de
]:- @astrojs/internal-helpers@0.6.1

Patch Changes
- Updated dependencies [
042d1de
]:- @astrojs/internal-helpers@0.6.1

Patch Changes
- #13355
042d1de
Thanks @ematipico! - Adds documentation to the assets utilities for remote service images.

Patch Changes
- Updated dependencies [
042d1de
]:- @astrojs/internal-helpers@0.6.1
- @astrojs/underscore-redirects@0.6.0

Patch Changes
- Updated dependencies [
042d1de
]:- @astrojs/internal-helpers@0.6.1

Patch Changes
- Updated dependencies []:
- @astrojs/markdown-remark@6.2.1


Patch Changes
-
#13343
a001a75
Thanks @dreyfus92! - Fix Astro DB seed failing when project path contains spaces. This resolves by properly decoding URL pathnames that contain encoded spaces (%20) before passing them to Vite's ssrLoadModule. -
Updated dependencies []:
- @astrojs/studio@0.1.4

Patch Changes
-
#13109
5c0e0ea
Thanks @arnottferels! - Adds support forconfig.lib
, which allows changing the destination of the files:export default defineConfig({ integrations: [partytown({ config: { + lib: '/assets/lib/~partytown/'; } })] })
Minor Changes
-
#2931
10b93b3
Thanks @HiDeoo! - Adds support for thetitle
,frame
, andmeta
fence attributes to code blocks.These new optional attributes add support for Expressive Code text & line markers. The following example renders a code block using a terminal frame with a title:
```js {% title="editor.exe" frame="terminal" %} console.log('Hello, world!'); ```
Any other text or line markers should be specified using the
meta
fence attribute. For example, the following code block renders a code block using thediff
syntax combined with thejs
language syntax highlighting and themarkers
text highlighted:```diff {% meta="lang=js 'markers'" %} function thisIsJavaScript() { // This entire block gets highlighted as JavaScript, // and we can still add diff markers to it! - console.log('Old code to be removed') + console.log('New and shiny code!') } ```
To learn more about all the available options, check out the Expressive Code documentation.

Minor Changes
- #13330
5e7646e
Thanks @ematipico! - Adds the ability to identifybun
as the preferred package manager.

🚀 Features
- page: Add
/highlights
page to show creative work or curated posts - by @lin-stephanie in #20 (352ae) - Support dynamic import of local images in
CardItem
andSwiperCarousel
- by @lin-stephanie (bb327)
🐞 Bug Fixes
- Convert formatted date based on
SITE.lang
- by @lin-stephanie (c5cfa)
🏡 Chore
- Fine-tune coding - by @lin-stephanie (81219)
- Update docs:
/highlights
Page & Choosing a Math Rendering Engine - by @lin-stephanie and @y-cg (0ac83) - Update deps - by @lin-stephanie (2f4a8)
View changes on GitHub

Minor Changes
-
#13254
1e11f5e
Thanks @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 (
localImagePaths
andremoteImagePaths
) which allow for the possibility of controlling the behavior of each type of image separately in the future.
Patch Changes
- Updated dependencies [
1e11f5e
]:- @astrojs/internal-helpers@0.6.0

Minor Changes
-
#13211
7ea0aba
Thanks @slawekkolodziej! - Adds support for regular expressions in ISR exclude listPreviously, excluding a page from ISR required explicitly listing it in
isr.exclude
. As websites grew larger, maintaining this list became increasingly difficult, especially for multiple API routes and pages that needed server-side rendering.To address this, ISR exclusions now support regular expressions, allowing for more flexible and scalable configurations.
// astro.config.mjs import vercel from '@astrojs/vercel/serverless'; export default defineConfig({ output: 'server', adapter: vercel({ isr: { exclude: [ '/preview', // Excludes a specific route (e.g., pages/preview.astro) '/auth/[page]', // Excludes a dynamic route (e.g., pages/auth/[page].astro) /^\/api\/.+/, // Excludes all routes starting with /api/ ], }, }), });
Patch Changes
-
#13323
80926fa
Thanks @ematipico! - Updatesesbuild
andvite
to the latest to avoid false positives audits warnings caused byesbuild
. -
Updated dependencies [
1e11f5e
]:- @astrojs/internal-helpers@0.6.0


Patch Changes
- #13323
80926fa
Thanks @ematipico! - Updatesesbuild
andvite
to the latest to avoid false positives audits warnings caused byesbuild
.

Patch Changes
- #13323
80926fa
Thanks @ematipico! - Updatesesbuild
andvite
to the latest to avoid false positives audits warnings caused byesbuild
.

Patch Changes
- Updated dependencies [
1e11f5e
]:- @astrojs/internal-helpers@0.6.0

Patch Changes
- #13323
80926fa
Thanks @ematipico! - Updatesesbuild
andvite
to the latest to avoid false positives audits warnings caused byesbuild
.



Patch Changes
- #13251
3842ce5
Thanks @florian-lefebvre! - Fixes a case where the compiler could not be resolved automatically

Patch Changes
- #13190
c6bf6b3
Thanks @lee-arnold! - Fixes the image endpoint entrypoint


Major Changes (153a8da
)
- Update Configuration Structure
- Renamed
loadMode
tomode
- Removed
modeConfig
; options are now configured per mode directly
- Renamed
- In
repoList
mode, whenentryReturnType: 'byRepository'
, renamedrepoReleases
in the entry Zod schema toreleases
- Add
clearStore
option to control whether to clear store before saving new data

Minor Changes
- Add
clearStore
option to control whether to clear store before saving new data (d03abe0
)

Minor Changes (2140c1c
)
- Support
uris
for direct Bluesky post URLs - Skip if
uris
unchanged, unlesssrc/content/config.ts
orsrc/content.config.ts
changes - Rename the
linkTextType
option value from'display-url'
to'post-text'
- Update the
link
field to usedid
instead ofhandle
within the post URL string - Update the entry Zod schema

Minor Changes
-
#13145
8d4e566
Thanks @ascorbic! - Automatically configures filesystem storage when experimental session enabledIf the
experimental.session
flag is enabled when using the Node adapter, Astro will automatically configure session storage using the filesystem driver. You can still manually configure session storage if you need to use a different driver or want to customize the session storage configuration.See the experimental session docs for more information on configuring session storage.

Minor Changes (6f5e32e
)
- Support retrieving post URL (
link
) and rendered HTML (html
) whenfetchThread: false
orfetchThread: true
+fetchOnlyAuthorReplies: true
- Export
renderPostAsHtml
andgetPostLink
- Batch process
GET /xrpc/app.bsky.feed.getPosts
to avoid exceeding 25 URIs per request - Update docs

Last fetched: | Scheduled refresh: Every Saturday
See Customizing GitHub Activity Pages to configure your own
Inspired by releases.antfu.me