diff --git a/.changeset/silent-dodos-develop.md b/.changeset/silent-dodos-develop.md deleted file mode 100644 index 89b8292..0000000 --- a/.changeset/silent-dodos-develop.md +++ /dev/null @@ -1,28 +0,0 @@ ---- -'starlight-versions': minor ---- - -Adds support for Astro v5, drops support for Astro v4. - -⚠️ **BREAKING CHANGE:** The minimum supported version of Starlight is now `0.30.0`. - -Please follow the [upgrade guide](https://github.com/withastro/starlight/releases/tag/%40astrojs/starlight%400.30.0) to update your project. - -After upgrading, you will also need to update the `versions` collection in your `src/content.config.ts` file to use the new `docsVersionsLoader`: - -```diff - // src/content.config.ts - import { defineCollection } from "astro:content"; - import { docsLoader } from "@astrojs/starlight/loaders"; - import { docsSchema } from "@astrojs/starlight/schema"; --import { docsVersionsSchema } from 'starlight-versions/schema' -+import { docsVersionsLoader } from 'starlight-versions/loader' - - export const collections = { - docs: defineCollection({ loader: docsLoader(), schema: docsSchema() }), -- versions: defineCollection({ type: 'data', schema: docsVersionsSchema() }), -+ versions: defineCollection({ loader: docsVersionsLoader() }), - }; -``` - -Note that the [`legacy.collections` flag](https://docs.astro.build/en/reference/legacy-flags/#collections) is not supported by this plugin and you should update your collections to use Astro's new Content Layer API. diff --git a/packages/starlight-versions/CHANGELOG.md b/packages/starlight-versions/CHANGELOG.md new file mode 100644 index 0000000..0dc0747 --- /dev/null +++ b/packages/starlight-versions/CHANGELOG.md @@ -0,0 +1,30 @@ +# starlight-versions + +## 0.4.0 + +### Minor Changes + +- [#15](https://github.com/HiDeoo/starlight-versions/pull/15) [`ecd96ed`](https://github.com/HiDeoo/starlight-versions/commit/ecd96ed4aa4474bb418669e8113bb9e1af0f7536) Thanks [@HiDeoo](https://github.com/HiDeoo)! - Adds support for Astro v5, drops support for Astro v4. + + ⚠️ **BREAKING CHANGE:** The minimum supported version of Starlight is now `0.30.0`. + + Please follow the [upgrade guide](https://github.com/withastro/starlight/releases/tag/%40astrojs/starlight%400.30.0) to update your project. + + After upgrading, you will also need to update the `versions` collection in your `src/content.config.ts` file to use the new `docsVersionsLoader`: + + ```diff + // src/content.config.ts + import { defineCollection } from "astro:content"; + import { docsLoader } from "@astrojs/starlight/loaders"; + import { docsSchema } from "@astrojs/starlight/schema"; + -import { docsVersionsSchema } from 'starlight-versions/schema' + +import { docsVersionsLoader } from 'starlight-versions/loader' + + export const collections = { + docs: defineCollection({ loader: docsLoader(), schema: docsSchema() }), + - versions: defineCollection({ type: 'data', schema: docsVersionsSchema() }), + + versions: defineCollection({ loader: docsVersionsLoader() }), + }; + ``` + + Note that the [`legacy.collections` flag](https://docs.astro.build/en/reference/legacy-flags/#collections) is not supported by this plugin and you should update your collections to use Astro's new Content Layer API. diff --git a/packages/starlight-versions/package.json b/packages/starlight-versions/package.json index 8b35f66..676ee5a 100644 --- a/packages/starlight-versions/package.json +++ b/packages/starlight-versions/package.json @@ -1,6 +1,6 @@ { "name": "starlight-versions", - "version": "0.3.1", + "version": "0.4.0", "license": "MIT", "description": "Starlight plugin to version documentation pages.", "author": "HiDeoo (https://hideoo.dev)",