astro-docs-template
astro-docs-template copied to clipboard
Update astro monorepo
This PR contains the following updates:
| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| @astrojs/preact (source) | 3.0.1 -> 3.5.4 |
||||
| @astrojs/react (source) | 3.0.5 -> 3.6.3 |
||||
| @astrojs/sitemap (source) | 3.0.3 -> 3.4.0 |
Release Notes
withastro/astro (@astrojs/preact)
v3.5.4
Patch Changes
- #12481
8a46e80Thanks @marbrex! - Resolvevitepeer dependency problem for strict package managers like Yarn in PnP mode.
v3.5.3
Patch Changes
- #11930
4a44e82Thanks @lukasbachlechner! - Preact components no longer throw an error if a property is null.
v3.5.2
Patch Changes
- #11834
5f2536bThanks @ph1p! - Preact signals are now serialized correctly in arrays when they are given to components.
v3.5.1
Patch Changes
- #11464
2cdb685Thanks @rschristian! - Swap outpreact-ssr-prepassforrenderToStringAsyncfrompreact-render-to-string
v3.5.0
Minor Changes
-
#11234
4385bf7Thanks @ematipico! - Adds a new function calledaddServerRendererto the Container API. Use this function to manually store renderers inside the instance of your container.This new function should be preferred when using the Container API in environments like on-demand pages:
import type { APIRoute } from 'astro'; import { experimental_AstroContainer } from 'astro/container'; import reactRenderer from '@​astrojs/react/server.js'; import vueRenderer from '@​astrojs/vue/server.js'; import ReactComponent from '../components/button.jsx'; import VueComponent from '../components/button.vue'; // MDX runtime is contained inside the Astro core import mdxRenderer from 'astro/jsx/server.js'; // In case you need to import a custom renderer import customRenderer from '../renderers/customRenderer.js'; export const GET: APIRoute = async (ctx) => { const container = await experimental_AstroContainer.create(); container.addServerRenderer({ renderer: reactRenderer }); container.addServerRenderer({ renderer: vueRenderer }); container.addServerRenderer({ renderer: customRenderer }); // You can pass a custom name too container.addServerRenderer({ name: 'customRenderer', renderer: customRenderer, }); const vueComponent = await container.renderToString(VueComponent); return await container.renderToResponse(Component); };
v3.4.0
Minor Changes
-
#11144
803dd80Thanks @ematipico! - The integration now exposes a function calledgetContainerRenderer, that can be used inside the Container APIs to load the relative renderer.import { experimental_AstroContainer as AstroContainer } from 'astro/container'; import ReactWrapper from '../src/components/ReactWrapper.astro'; import { loadRenderers } from 'astro:container'; import { getContainerRenderer } from '@​astrojs/react'; test('ReactWrapper with react renderer', async () => { const renderers = await loadRenderers([getContainerRenderer()]); const container = await AstroContainer.create({ renderers, }); const result = await container.renderToString(ReactWrapper); expect(result).toContain('Counter'); expect(result).toContain('Count: <!-- -->5'); });
v3.3.0
Minor Changes
-
#10938
fd508a0Thanks @florian-lefebvre! - Adds adevtoolsoptionYou can enable Preact devtools in development by setting
devtools: truein yourpreact()integration config:import { defineConfig } from 'astro/config'; import preact from '@​astrojs/preact'; export default defineConfig({ integrations: [preact({ devtools: true })], });
v3.2.0
Minor Changes
-
#10689
683d51a5eecafbbfbfed3910a3f1fbf0b3531b99Thanks @ematipico! - Deprecate support for versions of Node.js older thanv18.17.1for Node.js 18, older thanv20.0.3for Node.js 20, and the complete Node.js v19 release line.This change is in line with Astro's Node.js support policy.
v3.1.2
Patch Changes
- #10585
ad50784adc6f262fc563999e97df3a5dc9087c88Thanks @rschristian! - Fixes (theoretical) edge case in Preact integration's JSX aliases
v3.1.1
Patch Changes
- #10200
c692d0c66a5062937e47402dc700d41c2a5dfc5cThanks @Princesseuh! - Fixes passing children to server-rendered components causing an error
v3.1.0
Minor Changes
-
#9524
0903ef90494e9c8bd0272347a0cdd51eca7f4648Thanks @aleksandrjet! - Allows rendering lazy components.You can now use lazy components with Suspense:
import { lazy, Suspense } from 'preact/compat'; const HeavyComponent = lazy(() => import('./HeavyComponent')); const Component = () => { return ( <Suspense fallback={<p>Loading...</p>}> <HeavyComponent foo="bar" /> </Suspense> ); };
v3.0.2
Patch Changes
-
#9482
72b26daf694b213918f02d0fcbf90ab5b7ebc31fThanks @natemoo-re! - Improves compatibility with the Qwik adapter -
#9479
1baf0b0d3cbd0564954c2366a7278794fad6726eThanks @sarah11918! - Updates README
withastro/astro (@astrojs/react)
v3.6.3
Patch Changes
- #12481
8a46e80Thanks @marbrex! - Resolvevitepeer dependency problem for strict package managers like Yarn in PnP mode.
v3.6.2
Patch Changes
- #11624
7adb350Thanks @bluwy! - Prevents throwing errors when checking if a component is a React component in runtime
v3.6.1
Patch Changes
-
#11571
1c3265aThanks @bholmesdev! - BREAKING CHANGE to the experimental Actions API only. Install the latest@astrojs/reactintegration as well if you're using React 19 features.Make
.safe()the default return value for actions. This means{ data, error }will be returned when calling an action directly. If you prefer to get the data while allowing errors to throw, chain the.orThrow()modifier.import { actions } from 'astro:actions'; // Before const { data, error } = await actions.like.safe(); // After const { data, error } = await actions.like(); // Before const newLikes = await actions.like(); // After const newLikes = await actions.like.orThrow();
v3.6.0
Minor Changes
-
#11234
4385bf7Thanks @ematipico! - Adds a new function calledaddServerRendererto the Container API. Use this function to manually store renderers inside the instance of your container.This new function should be preferred when using the Container API in environments like on-demand pages:
import type { APIRoute } from 'astro'; import { experimental_AstroContainer } from 'astro/container'; import reactRenderer from '@​astrojs/react/server.js'; import vueRenderer from '@​astrojs/vue/server.js'; import ReactComponent from '../components/button.jsx'; import VueComponent from '../components/button.vue'; // MDX runtime is contained inside the Astro core import mdxRenderer from 'astro/jsx/server.js'; // In case you need to import a custom renderer import customRenderer from '../renderers/customRenderer.js'; export const GET: APIRoute = async (ctx) => { const container = await experimental_AstroContainer.create(); container.addServerRenderer({ renderer: reactRenderer }); container.addServerRenderer({ renderer: vueRenderer }); container.addServerRenderer({ renderer: customRenderer }); // You can pass a custom name too container.addServerRenderer({ name: 'customRenderer', renderer: customRenderer, }); const vueComponent = await container.renderToString(VueComponent); return await container.renderToResponse(Component); };
v3.5.0
Minor Changes
-
#11144
803dd80Thanks @ematipico! - The integration now exposes a function calledgetContainerRenderer, that can be used inside the Container APIs to load the relative renderer.import { experimental_AstroContainer as AstroContainer } from 'astro/container'; import ReactWrapper from '../src/components/ReactWrapper.astro'; import { loadRenderers } from 'astro:container'; import { getContainerRenderer } from '@​astrojs/react'; test('ReactWrapper with react renderer', async () => { const renderers = await loadRenderers([getContainerRenderer()]); const container = await AstroContainer.create({ renderers, }); const result = await container.renderToString(ReactWrapper); expect(result).toContain('Counter'); expect(result).toContain('Count: <!-- -->5'); });
v3.4.0
Minor Changes
-
#11071
8ca7c73Thanks @bholmesdev! - Adds two new functionsexperimental_getActionState()andexperimental_withState()to support the React 19useActionState()hook when using Astro Actions. This introduces progressive enhancement when calling an Action with thewithState()utility.This example calls a
likeaction that accepts apostIdand returns the number of likes. Pass this action to theexperimental_withState()function to apply progressive enhancement info, and apply touseActionState()to track the result:import { actions } from 'astro:actions'; import { experimental_withState } from '@​astrojs/react/actions'; export function Like({ postId }: { postId: string }) { const [state, action, pending] = useActionState( experimental_withState(actions.like), 0, // initial likes ); return ( <form action={action}> <input type="hidden" name="postId" value={postId} /> <button disabled={pending}>{state} ❤️</button> </form> ); }You can also access the state stored by
useActionState()from your actionhandler. Callexperimental_getActionState()with the API context, and optionally apply a type to the result:import { defineAction, z } from 'astro:actions'; import { experimental_getActionState } from '@​astrojs/react/actions'; export const server = { like: defineAction({ input: z.object({ postId: z.string(), }), handler: async ({ postId }, ctx) => { const currentLikes = experimental_getActionState<number>(ctx); // write to database return currentLikes + 1; }, }), };
v3.3.4
Patch Changes
- #10986
4d16381Thanks @emish89! - Fixes incorrectpeerDependenciesfor@types/reactand@types/react-dom
v3.3.3
Patch Changes
- #10942
d47baa4Thanks @matthewp! - Updates package to support React 19 beta
v3.3.2
Patch Changes
- #10893
fd7a9edThanks @Angrigo! - Removes using deprecatedReactDOMServer.renderToStaticNodeStreamAPI
v3.3.1
Patch Changes
- #10855
f6bddd3Thanks @lamATnginx! - Fix Redoc usage in React integration
v3.3.0
Minor Changes
-
#10689
683d51a5eecafbbfbfed3910a3f1fbf0b3531b99Thanks @ematipico! - Deprecate support for versions of Node.js older thanv18.17.1for Node.js 18, older thanv20.0.3for Node.js 20, and the complete Node.js v19 release line.This change is in line with Astro's Node.js support policy.
v3.2.0
Minor Changes
- #10675
14f1d49a10541fecc4c10def8a094322442ccf23Thanks @fightingcat! - Expose Babel config for @astro/react.
v3.1.1
Patch Changes
- #10654
195f51f82a44df32be73865949aabee0d46ffe61Thanks @matthewp! - Mark @material-tailwind/react as noExternal
v3.1.0
Minor Changes
-
#10136
9cd84bd19b92fb43ae48809f575ee12ebd43ea8fThanks @matthewp! - Changes the default behavior oftransition:persistto update the props of persisted islands upon navigation. Also adds a new view transitions optiontransition:persist-props(default:false) to prevent props from updating as needed.Islands which have the
transition:persistproperty to keep their state when using the<ViewTransitions />router will now have their props updated upon navigation. This is useful in cases where the component relies on page-specific props, such as the current page title, which should update upon navigation.For example, the component below is set to persist across navigation. This component receives a
productsprops and might have some internal state, such as which filters are applied:<ProductListing transition:persist products={products} />Upon navigation, this component persists, but the desired
productsmight change, for example if you are visiting a category of products, or you are performing a search.Previously the props would not change on navigation, and your island would have to handle updating them externally, such as with API calls.
With this change the props are now updated, while still preserving state.
You can override this new default behavior on a per-component basis using
transition:persist-props=trueto persist both props and state during navigation:<ProductListing transition:persist-props="true" products={products} />
v3.0.10
Patch Changes
- #9849
20ca3154fb37049cbcd51b06d9fa2ef25ac25a36Thanks @StandardGage! - Fixes an issue where passing void elements (img, etc..) did not work with theexperimentalReactChildrenoption enabled
v3.0.9
Patch Changes
-
#9482
72b26daf694b213918f02d0fcbf90ab5b7ebc31fThanks @natemoo-re! - Improves compatibility with the Qwik adapter -
#9479
1baf0b0d3cbd0564954c2366a7278794fad6726eThanks @sarah11918! - Updates README
v3.0.8
Patch Changes
-
#9403
7eb9fe8a7Thanks @knpwrs! - Prevents unsupportedforwardRefcomponents created by Preact from being rendered by React -
#9452
e83b5095fThanks @florian-lefebvre! - Upgrades vite to latest
v3.0.7
Patch Changes
- #9122
1c48ed286Thanks @bluwy! - Adds Vite 5 support. There are no breaking changes from Astro. Check the Vite migration guide for details of the breaking changes from Vite instead.
v3.0.6
Patch Changes
withastro/astro (@astrojs/sitemap)
v3.4.0
Minor Changes
-
#13753
90293deThanks @mattyoho! - Customize the filenames of sitemap XML files generated by the@astro/sitemapintegration by settingfilenameBasein the integration configuration settings. This may be useful when deploying an Astro site at a path on a domain with preexisting sitemap files.Generated sitemap files will appear at
/sitemap-0.xmland/sitemap-index.xmlby default, which may conflict with preexisting files. SetfilenameBaseto a custom value to avoid that if so:import { defineConfig } from 'astro/config'; import sitemap from '@​astrojs/sitemap'; export default defineConfig({ site: 'https://example.com', integrations: [ sitemap({ filenameBase: 'astronomy-sitemap', }), ], });This will yield sitemap and index files as
https://example.com/astronomy-sitemap-0.xmlandhttps://example.com/astronomy-sitemap-index.xml.
v3.3.1
Patch Changes
- #13591
5dd2d3fThanks @florian-lefebvre! - Removes unused code
v3.3.0
Minor Changes
- #13448
91c9503Thanks @ematipico! - Add support for XSL in sitemap-index.xml
v3.2.1
Patch Changes
- #12156
07754f5Thanks @mingjunlu! - Adds missingxslURLproperty toSitemapOptionstype.
v3.2.0
Minor Changes
v3.1.6
Patch Changes
- #11263
7d59750Thanks @wackbyte! - Refactor to use Astro's integration logger for logging
v3.1.5
Patch Changes
- #10779
cefeadfThanks @adrianlyjak! - Fixes false positives for status code routes like404and500when generating sitemaps.
v3.1.4
Patch Changes
- #10772
0e22462d1534afc8f7bb6782f86db680c7a5f245Thanks @gislerro! - Fixes an issue where the root url does not follow thetrailingSlashconfig option
v3.1.3
Patch Changes
- #10795
1ce22881c657becf0397b83ac393fb5d2399104cThanks @bluwy! - Improves performance when generating the sitemap data
v3.1.2
Patch Changes
- #10557
5f7e9c47e01116f6ec74b33770f480404680956aThanks @mingjunlu! - Fixes an issue where the base path is missing insitemap-index.xml.
v3.1.1
Patch Changes
-
#10179
6343f6a438d790fa16a0dd268f4a51def4fa0f33Thanks @ematipico! - Revert https://github.com/withastro/astro/pull/9846The feature to customize the file name of the sitemap was reverted due to some internal issues with one of the dependencies. With an non-deterministic behaviour, the sitemap file was sometime emitted with incorrect syntax.
-
#9975
ec7d2ebbd96b8c2dfdadaf076bbf7953007536edThanks @moose96! - Fixes URL generation for routes that rest parameters and start with/
v3.1.0
Minor Changes
-
#9846
9b78c992750cdb99c40a89a00ea2a0d1c00877d7Thanks @ktym4a! - Adds a new configuration optionprefixthat allows you to change the defaultsitemap-*.xmlfile name.By default, running
astro buildcreates bothsitemap-index.xmlandsitemap-0.xmlin your output directory.To change the names of these files (e.g. to
astrosite-index.xmlandastrosite-0.xml), set theprefixoption in yoursitemapintegration configuration:import { defineConfig } from 'astro/config'; import sitemap from '@​astrojs/sitemap'; export default defineConfig({ site: 'https://example.com', integrations: [ sitemap({ prefix: 'astrosite-', }), ], });This option is useful when Google Search Console is unable to fetch your default sitemap files, but can read renamed files.
v3.0.5
Patch Changes
- #9704
b325fada567892b63ecae87c1ff845c8514457baThanks @andremralves! - Fixes generated URLs when using abasewith a SSR adapter
v3.0.4
Patch Changes
- #9479
1baf0b0d3cbd0564954c2366a7278794fad6726eThanks @sarah11918! - Updates README
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.
- [ ] If you want to rebase/retry this PR, check this box
This PR was generated by Mend Renovate. View the repository job log.
Run & review this pull request in StackBlitz Codeflow.
Deploy Preview for advanced-astro-docs failed.
| Name | Link |
|---|---|
| Latest commit | e461d9eeafb6c7efad11577b52bee3e15cf69e21 |
| Latest deploy log | https://app.netlify.com/sites/advanced-astro-docs/deploys/663210fc3d318e0008447337 |
Deploy Preview for astro-docs failed.
| Name | Link |
|---|---|
| Latest commit | e461d9eeafb6c7efad11577b52bee3e15cf69e21 |
| Latest deploy log | https://app.netlify.com/sites/astro-docs/deploys/663210fca4ffeb0008a23ead |
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
| Diff | Package | Supply Chain Security |
Vulnerability | Quality | Maintenance | License |
|---|---|---|---|---|---|---|
| @astrojs/preact@3.0.1 ⏵ 3.5.4 | ||||||
| @astrojs/sitemap@3.0.3 ⏵ 3.3.1 | ||||||
| @astrojs/react@3.0.5 ⏵ 3.6.3 |
Deploy Preview for astro-docs failed.
| Name | Link |
|---|---|
| Latest commit | 191856d895deb1a2d5b5940e435242779e333116 |
| Latest deploy log | https://app.netlify.com/sites/astro-docs/deploys/680a26273fa568000820bd1b |
Deploy Preview for advanced-astro-docs failed.
| Name | Link |
|---|---|
| Latest commit | 191856d895deb1a2d5b5940e435242779e333116 |
| Latest deploy log | https://app.netlify.com/sites/advanced-astro-docs/deploys/680a26279233620008c34236 |