Conversation
|
Important Review skippedBot user detected. To trigger a single review, invoke the You can disable this status message by setting the 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Join our Discord community for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
|
All alerts resolved. Learn more about Socket for GitHub. This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored. |
3c6395c to
e412f55
Compare
e412f55 to
d292537
Compare
d292537 to
2e04c5d
Compare
b0969f0 to
5d7ac83
Compare
5d7ac83 to
15f9ffe
Compare
15f9ffe to
42f3245
Compare
42f3245 to
5487593
Compare
5487593 to
8fc19e1
Compare
8fc19e1 to
add8146
Compare
add8146 to
ebcf71f
Compare
This PR contains the following updates:
3.0.10->3.6.34.4.8->4.16.18Release Notes
withastro/astro (@astrojs/react)
v3.6.3Compare Source
Patch Changes
8a46e80Thanks @marbrex! - Resolvevitepeer dependency problem for strict package managers like Yarn in PnP mode.v3.6.2Compare Source
Patch Changes
7adb350Thanks @bluwy! - Prevents throwing errors when checking if a component is a React component in runtimev3.6.1Compare Source
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.v3.6.0Compare Source
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:
v3.5.0Compare Source
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.v3.4.0Compare Source
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: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:v3.3.4Compare Source
Patch Changes
4d16381Thanks @emish89! - Fixes incorrectpeerDependenciesfor@types/reactand@types/react-domv3.3.3Compare Source
Patch Changes
d47baa4Thanks @matthewp! - Updates package to support React 19 betav3.3.2Compare Source
Patch Changes
fd7a9edThanks @Angrigo! - Removes using deprecatedReactDOMServer.renderToStaticNodeStreamAPIv3.3.1Compare Source
Patch Changes
f6bddd3Thanks @lamATnginx! - Fix Redoc usage in React integrationv3.3.0Compare Source
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.0Compare Source
Minor Changes
14f1d49a10541fecc4c10def8a094322442ccf23Thanks @fightingcat! - Expose Babel config for @astro/react.v3.1.1Compare Source
Patch Changes
195f51f82a44df32be73865949aabee0d46ffe61Thanks @matthewp! - Mark @material-tailwind/react as noExternalv3.1.0Compare Source
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: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:withastro/astro (astro)
v4.16.18Compare Source
Patch Changes
#12757
d0aaac3Thanks @matthewp! - Remove all assets created from the server build#12757
d0aaac3Thanks @matthewp! - Clean server sourcemaps from static outputv4.16.17Compare Source
Patch Changes
e7d14c3Thanks @ematipico! - Fixes an issue where thecheckOriginfeature wasn't correctly checking thecontent-typeheaderv4.16.16Compare Source
Patch Changes
#12542
65e50ebThanks @kadykov! - Fix JPEG image size determination#12525
cf0d8b0Thanks @ematipico! - Fixes an issue where withi18nenabled, Astro couldn't render the404.astrocomponent for non-existent routes.v4.16.15Compare Source
Patch Changes
b140a3fThanks @ematipico! - Fixes a regression where Astro was trying to accessRequest.headersv4.16.14Compare Source
Patch Changes
#12480
c3b7e7cThanks @matthewp! - Removes the default throw behavior inastro:env#12444
28dd3ceThanks @ematipico! - Fixes an issue where a server island hydration script might fail case the island ID misses from the DOM.#12476
80a9a52Thanks @florian-lefebvre! - Fixes a case where the Content Layerglob()loader would not update when renaming or deleting an entry#12418
25baa4eThanks @oliverlynch! - Fix cached image redownloading if it is the first asset#12477
46f6b38Thanks @ematipico! - Fixes an issue where the SSR build was emitting thedist/server/entry.mjsfile with an incorrect import at the top of the file/#12365
a23985bThanks @apatel369! - Fixes an issue whereAstro.currentLocalewas not correctly returning the locale for 404 and 500 pages.v4.16.13Compare Source
Patch Changes
#12436
453ec6bThanks @martrapp! - Fixes a potential null access in the clientside router#12392
0462219Thanks @apatel369! - Fixes an issue where scripts were not correctly injected during the build. The issue was triggered when there were injected routes with the sameentrypointand differentpatternv4.16.12Compare Source
Patch Changes
acac0afThanks @ematipico! - Fixes an issue where the dev server returns a 404 status code when a user middleware returns a validResponse.v4.16.11Compare Source
Patch Changes
#12305
f5f7109Thanks @florian-lefebvre! - Fixes a case where the error overlay would not escape the message#12402
823e73bThanks @ematipico! - Fixes a case where Astro allowed to call an action without usingAstro.callAction. This is now invalid, and Astro will show a proper error.v4.16.10Compare Source
Patch Changes
#12311
bf2723eThanks @dinesh-58! - Addscheckedto the list of boolean attributes.#12363
222f718Thanks @Fryuni! - Fixes code generated byastro addcommand when adding a version of an integration other than the defaultlatest.#12368
493fe43Thanks @bluwy! - Improves error logs when executing commands#12355
c4726d7Thanks @apatel369! - Improves error reporting for invalid frontmatter in MDX files during theastro buildcommand. The error message now includes the file path where the frontmatter parsing failed.v4.16.9Compare Source
Patch Changes
#12333
836cd91Thanks @imattacus! - Destroy the server response stream if async error is thrown#12358
7680349Thanks @spacedawwwg! - HonorsinlineAstroConfigparameter ingetViteConfigwhen creating a logger#12353
35795a1Thanks @hippotastic! - Fixes an issue in dev server watch file handling that could cause multiple restarts for a single file change.#12351
5751488Thanks @florian-lefebvre! - Reverts a change made in4.16.6that prevented usage ofastro:envsecrets inside middleware in SSR#12346
20e5a84Thanks @bluwy! - Fixes sourcemap generation when prefetch is enabled#12349
1fc83d3Thanks @norskeld! - Fixes thegetImageoptions type so it properly extendsImageTransformv4.16.8Compare Source
Patch Changes
#12338
9ca89b3Thanks @situ2001! - ResetsNODE_ENVto ensure install command run in dev mode#12286
9d6bcdbThanks @florian-lefebvre! - Fixes a case where a warning for experimentalastro:envsupport would be shown when using an adapter but not actually usingastro:env#12342
ffc836bThanks @liruifengv! - Fixes a typo in the command name of the CLI#12301
0cfc69dThanks @apatel369! - Fixes an issue with action handler context by passing the correct context (ActionAPIContext).#12312
5642ef9Thanks @koyopro! - Fixes an issue where usinggetViteConfig()returns incorrect and duplicate configuration#12245
1d4f6a4Thanks @bmenant! - Addcomponentsproperty to MDXInstance type definition (RenderResult and module import)#12340
94eaeeaThanks @ematipico! - Fixes an issue where Astro actions didn't work whenbasewas different from/v4.16.7Compare Source
Patch Changes
#12263
e9e8080Thanks @Fryuni! - Fixes conflict between server islands and on-demand dynamic routes in the form of/[...rest]or/[paramA]/[paramB].#12279
b781f88Thanks @jsparkdev! - Update wrong error message#12273
c2ee963Thanks @ascorbic! - Fixes an issue with some package managers where sites would not build if TypeScript was not installed.#12235
a75bc5eThanks @ematipico! - Fixes a bug where Astro Actions couldn't redirect to the correct pathname when there was a rewrite involved.#11839
ff522b9Thanks @icaliman! - Fixes error when returning a top-levelnullfrom an Astro file frontmatter#12272
388d237Thanks @ascorbic! - Correctly handles local images when using a base path in SSRv4.16.6Compare Source
Patch Changes
#11823
a3d30a6Thanks @DerTimonius! - fix: improve error message when inferSize is used in local images with the Image component#12227
8b1a641Thanks @florian-lefebvre! - Fixes a case where environment variables would not be refreshed when usingastro:env#12239
2b6daa5Thanks @ematipico! - BREAKING CHANGE to the experimental Container API onlyChanges the default page rendering behavior of Astro components in containers, and adds a new option
partial: falseto render full Astro pages as before.Previously, the Container API was rendering all Astro components as if they were full Astro pages containing
<!DOCTYPE html>by default. This was not intended, and now by default, all components will render as page partials: only the contents of the components without a page shell.To render the component as a full-fledged Astro page, pass a new option called
partial: falsetorenderToString()andrenderToResponse():v4.16.5Compare Source
Patch Changes
ff68ba5Thanks @martrapp! - Fixes an issue with cssesc in dev mode when settingvite.ssr.noExternal: truev4.16.4Compare Source
Patch Changes
#12223
79ffa5dThanks @ArmandPhilippot! - Fixes a false positive reported by the dev toolbar Audit app where a label was considered missing when associated with a buttonThe
buttonelement can be used with a label (e.g. to create a switch) and should not be reported as an accessibility issue when used as a child of alabel.#12199
c351352Thanks @ematipico! - Fixes a regression in the computation ofAstro.currentLocale#12222
fb55695Thanks @ematipico! - Fixes an issue where the edge middleware couldn't correctly compute the client IP address when callingctx.clientAddress()v4.16.3Compare Source
Patch Changes
#12220
b049359Thanks @bluwy! - Fixes accidental internalsetOnSetGetEnvparameter rename that caused runtime errors#12197
2aa2dfdThanks @ematipico! - Fix a regression where a port was incorrectly added to theAstro.urlv4.16.2Compare Source
Patch Changes
12b0022Thanks @bluwy! - Reverts https://github.com/withastro/astro/pull/12173 which causedCan't modify immutable headerswarnings and 500 errors on Cloudflare Pagesv4.16.1Compare Source
Patch Changes
#12177
a4ffbfaThanks @matthewp! - Ensure we target scripts for execution in the routerUsing
document.scriptsis unsafe because if the application has aname="scripts"this will shadow the built-indocument.scripts. Fix is to usegetElementsByTagNameto ensure we're only grabbing real scripts.#12173
2d10de5Thanks @ematipico! - Fixes a bug where Astro Actions couldn't redirect to the correct pathname when there was a rewrite involved.v4.16.0Compare Source
Minor Changes
#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:Then in your Markdown, you can use the alias as the language for a code block for syntax highlighting:
#11984
3ac2263Thanks @chaegumi! - Adds a newbuild.concurrenyconfiguration option to specify the number of pages to build in parallelIn most cases, you should not change the default value of
1.Use this option only when other attempts to reduce the overall rendering time (e.g. batch or cache long running tasks like fetch calls or data access) are not possible or are insufficient.
Use this option only if the refactors are not possible. If the number is set too high, the page rendering may slow down due to insufficient memory resources and because JS is single-threaded.
Patch Changes
#12160
c6fd1dfThanks @louisescher! - Fixes a bug whereastro.config.mtsandastro.config.ctsweren't reloading the dev server upon modifications.#12130
e96bcaeThanks @thehansys! - Fixes a bug in the parsing ofx-forwarded-\*Requestheaders, where multiple values assigned to those headers were not correctly parsed.Now, headers like
x-forwarded-proto: https,httpare correctly parsed.#12147
9db755aThanks @ascorbic! - Skips setting statusMessage header for HTTP/2 responseHTTP/2 doesn't support status message, so setting this was logging a warning.
#12151
bb6d37fThanks @ematipico! - Fixes an issue whereAstro.currentLocalewasn't incorrectly computed when thedefaultLocalebelonged to a custom locale path.Updated dependencies [
710a1a1]:v4.15.12Compare Source
Patch Changes
#12121
2490cebThanks @ascorbic! - Support passing the valuesInfinityand-Infinityas island props.#12118
f47b347Thanks @Namchee! - Removes thestrip-ansidependency in favor of the native Node API#12126
6e1dfebThanks @ascorbic! - Clear content layer cache when astro version changes#12117
a46839aThanks @ArmandPhilippot! - Updates Vite links to use their new domain#12124
499fbc9Thanks @ascorbic! - Allows special characters in Action names#12123
b8673dfThanks @Princesseuh! - Fixes missingbodyproperty on CollectionEntry types for content layer entries#12132
de35daaThanks @jcayzac! - Updates thecookiedependency to avoid the CVE 2024-47764 vulnerability.#12113
a54e520Thanks @ascorbic! - Adds a helpful error when attempting to render an undefined collection entryv4.15.11Compare Source
Patch Changes
#12097
11d447fThanks @ascorbic! - Fixes error where references in content layer schemas sometimes incorrectly report as missing#12108
918953bThanks @lameuler! - Fixes a bug where data URL images were not correctly handled. The bug resulted in anENAMETOOLONGerror.#12105
42037f3Thanks @ascorbic! - Returns custom statusText that has been set in a Response#12109
ea22558Thanks @ematipico! - Fixes a regression that was introduced by an internal refactor of how the middleware is loaded by the Astro application. The regression was introduced by #11550.When the edge middleware feature is opted in, Astro removes the middleware function from the SSR manifest, and this wasn't taken into account during the refactor.
#12106
d3a74daThanks @ascorbic! - Handles case where an immutable Response object is returned from an endpoint#12090
d49a537Thanks @markjaquith! - Server islands: changes the server island HTML placeholder comment so that it is much less likely to get removed by HTML minifiers.v4.15.10Compare Source
Patch Changes
#12084
12dae50Thanks @Princesseuh! - Adds missing filePath property on content layer entries#12046
d7779dfThanks @martrapp! - View transitions: Fixes Astro's fade animation to prevent flashing during morph transitions.#12043
1720c5bThanks @bluwy! - Fixes injected endpointprerenderoption detection#12095
76c5fbdThanks @TheOtterlord! - Fix installing non-stable versions of integrations withastro addv4.15.9Compare Source
Patch Changes
#12034
5b3ddfaThanks @ematipico! - Fixes an issue where the middleware wasn't called when a project uses404.astro.#12042
243ecb6Thanks @ematipico! - Fixes a problem in the Container API, where a polyfill wasn't correctly applied. This caused an issue in some environments wherecryptoisn't supported.#12038
26ea5e8Thanks @ascorbic! - Resolves image paths in content layer with initial slash as project-relativeWhen using the
image()schema helper, previously paths with an initial slash were treated as public URLs. This was to match the behavior of markdown images. However this is a change from before, where paths with an initial slash were treated as project-relative. This change restores the previous behavior, so that paths with an initial slash are treated as project-relative.v4.15.8Compare Source
Patch Changes
#12014
53cb41eThanks @ascorbic! - Fixes an issue where component styles were not correctly included in rendered MDX#12031
8c0cae6Thanks @ematipico! - Fixes a bug where the rewrite vianext(/*..*/)inside a middleware didn't compute the newAPIContext.params#12026
40e7a1bThanks @bluwy! - Initializes the Markdown processor only when there's.mdfiles#12028
d3bd673Thanks @bluwy! - Handles route collision detection only if it matchesgetStaticPaths#12027
dd3b753Thanks @fviolette! - Addselectedto the list of boolean attributes#12001
9be3e1bThanks @uwej711! - Remove dependency on path-to-regexpv4.15.7Compare Source
Patch Changes
#12000
a2f8c5dThanks @ArmandPhilippot! - Fixes an outdated link used to document Content Layer API#11915
0b59fe7Thanks @azhirov! - Fix: prevent island from re-rendering when using transition:persist (#11854)v4.15.6Compare Source
Patch Changes
#11993
ffba5d7Thanks @matthewp! - Fix getStaticPaths regressionThis reverts a previous change meant to remove a dependency, to fix a regression with multiple nested spread routes.
#11964
06eff60Thanks @TheOtterlord! - Add wayland (wl-copy) support toastro infov4.15.5Compare Source
Patch Changes
#11939
7b09c62Thanks @bholmesdev! - Adds support for Zod discriminated unions on Action form inputs. This allows forms with different inputs to be submitted to the same action, using a given input to decide which object should be used for validation.This example accepts either a
createorupdateform submission, and uses thetypefield to determine which object to validate against.The corresponding
createandupdateforms may look like this:v4.15.4Compare Source
Patch Changes
bd1d4aaThanks [@matthewp](https://redirect.github.com/mConfiguration
📅 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.
This PR was generated by Mend Renovate. View the repository job log.