Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(deps): update astro monorepo to v3 (major) #244

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented May 6, 2024

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
@astrojs/react (source) 2.2.1 -> 3.3.2 age adoption passing confidence
astro (source) 2.8.0 -> 3.6.5 age adoption passing confidence

Release Notes

withastro/astro (@​astrojs/react)

v3.3.2

Compare Source

Patch Changes

v3.3.1

Compare Source

Patch Changes

v3.3.0

Compare Source

Minor Changes

v3.2.0

Compare Source

Minor Changes

v3.1.1

Compare Source

Patch Changes

v3.1.0

Compare Source

Minor Changes
  • #​10136 9cd84bd19b92fb43ae48809f575ee12ebd43ea8f Thanks @​matthewp! - Changes the default behavior of transition:persist to update the props of persisted islands upon navigation. Also adds a new view transitions option transition:persist-props (default: false) to prevent props from updating as needed.

    Islands which have the transition:persist property 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 products props 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 products might 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=true to persist both props and state during navigation:

    <ProductListing transition:persist-props="true" products={products} />

v3.0.10

Compare Source

Patch Changes

v3.0.9

Compare Source

Patch Changes

v3.0.8

Compare Source

Patch Changes

v3.0.7

Compare Source

Patch Changes

v3.0.6

Compare Source

Patch Changes
  • #​9141 af43fb517 Thanks @​lilnasy! - Fixes an issue where slotting self-closing elements (img, br, hr) into react components with experimentalReactChildren enabled led to an error.

v3.0.5

Compare Source

Patch Changes

v3.0.4

Compare Source

Patch Changes

v3.0.3

Compare Source

Patch Changes

v3.0.2

Compare Source

Patch Changes

v3.0.1

Compare Source

Patch Changes

v3.0.0

Compare Source

Major Changes
  • #​8188 d0679a666 Thanks @​ematipico! - Remove support for Node 16. The lowest supported version by Astro and all integrations is now v18.14.1. As a reminder, Node 16 will be deprecated on the 11th September 2023.

  • #​8179 6011d52d3 Thanks @​matthewp! - Astro 3.0 Release Candidate

  • #​7924 519a1c4e8 Thanks @​matthewp! - Support for React Refresh

    The React integration now fully supports React Refresh and is backed by @vitejs/plugin-react.

    Also included in this change are new include and exclude config options. Use these if you want to use React alongside another JSX framework; include specifies files to be compiled for React and exclude does the opposite.

Patch Changes

v2.3.2

Compare Source

Patch Changes

v2.3.1

Compare Source

Patch Changes

v2.3.0

Compare Source

Minor Changes
  • #​8082 16a3fdf93 Thanks @​matthewp! - Optionally parse React slots as React children.

    This adds a new configuration option for the React integration experimentalReactChildren:

    export default {
      integrations: [
        react({
          experimentalReactChildren: true,
        }),
      ],
    };

    With this enabled, children passed to React from Astro components via the default slot are parsed as React components.

    This enables better compatibility with certain React components which manipulate their children.

v2.2.2

Compare Source

Patch Changes
  • #​8075 da517d405 Thanks @​SudoCat! - fix a bug where react identifierPrefix was set to null for client:only components causing React.useId to generate ids prefixed with null
withastro/astro (astro)

v3.6.5

Compare Source

Patch Changes
  • #​10287 a90d685d7 Thanks @​ematipico! - Fixes an issue where in Node SSR, the image endpoint could be used maliciously to reveal unintended information about the underlying system.

    Thanks to Google Security Team for reporting this issue.

v3.6.4

Compare Source

Patch Changes
  • #​9226 8f8a40e93 Thanks @​outofambit! - Fix i18n fallback routing with routing strategy of always-prefix

  • #​9179 3f28336d9 Thanks @​lilnasy! - Fixes an issue where the presence of a slot in a page led to an error.

  • #​9219 067a65f5b Thanks @​natemoo-re! - Fix edge case where <style> updates inside of .astro files would ocassionally fail to update without reloading the page.

  • #​9236 27d3e86e4 Thanks @​ematipico! - The configuration i18n.routingStrategy has been replaced with an object called routing.

    export default defineConfig({
      experimental: {
          i18n: {
    -          routingStrategy: "prefix-always",
    +          routing: {
    +              prefixDefaultLocale: true,
    +          }
          }
      }
    })
    export default defineConfig({
      experimental: {
          i18n: {
    -          routingStrategy: "prefix-other-locales",
    +          routing: {
    +              prefixDefaultLocale: false,
    +          }
          }
      }
    })

v3.6.3

Compare Source

Patch Changes

v3.6.2

Compare Source

Patch Changes

v3.6.1

Compare Source

Patch Changes

v3.6.0

Compare Source

Minor Changes
  • #​9090 c87223c21 Thanks @​martrapp! - Take full control over the behavior of view transitions!

    Three new events now complement the existing astro:after-swap and astro:page-load events:

    'astro:before-preparation'; // Control how the DOM and other resources of the target page are loaded
    'astro:after-preparation'; // Last changes before taking off? Remove that loading indicator? Here you go!
    'astro:before-swap'; // Control how the DOM is updated to match the new page

    The astro:before-* events allow you to change properties and strategies of the view transition implementation.
    The astro:after-* events are notifications that a phase is complete.
    Head over to docs to see the full view transitions lifecycle including these new events!

  • #​9092 0ea4bd47e Thanks @​smitbarmase! - Changes the fallback prefetch behavior on slow connections and when data saver mode is enabled. Instead of disabling prefetch entirely, the tap strategy will be used.

  • #​9166 cba6cf32d Thanks @​matthewp! - The Picture component is no longer experimental

    The <Picture /> component, part of astro:assets, has exited experimental status and is now recommended for use. There are no code changes to the component, and no upgrade to your project is necessary.

    This is only a change in documentation/recommendation. If you were waiting to use the <Picture /> component until it had exited the experimental stage, wait no more!

  • #​9092 0ea4bd47e Thanks @​smitbarmase! - Adds a ignoreSlowConnection option to the prefetch() API to prefetch even on data saver mode or slow connection.

v3.5.7

Compare Source

Patch Changes

v3.5.6

Compare Source

Patch Changes

v3.5.5

Compare Source

Patch Changes
  • #​9091 536c6c9fd Thanks @​ematipico! - The routingStrategy prefix-always should not force its logic to endpoints. This fixes some regression with astro:assets and @astrojs/rss.

  • #​9102 60e8210b0 Thanks @​Princesseuh! - In the dev overlay, when there's too many plugins enabled at once, some of the plugins will now be hidden in a separate sub menu to avoid the bar becoming too long

v3.5.4

Compare Source

Patch Changes

v3.5.3

Compare Source

Patch Changes

v3.5.2

Compare Source

Patch Changes

v3.5.1

Compare Source

Patch Changes

v3.5.0

Compare Source

Minor Changes
  • #​8869 f5bdfa272 Thanks @​matthewp! - ## Integration Hooks to add Middleware

    It's now possible in Astro for an integration to add middleware on behalf of the user. Previously when a third party wanted to provide middleware, the user would need to create a src/middleware.ts file themselves. Now, adding third-party middleware is as easy as adding a new integration.

    For integration authors, there is a new addMiddleware function in the astro:config:setup hook. This function allows you to specify a middleware module and the order in which it should be applied:

    // my-package/middleware.js
    import { defineMiddleware } from 'astro:middleware';
    
    export const onRequest = defineMiddleware(async (context, next) => {
      const response = await next();
    
      if (response.headers.get('content-type') === 'text/html') {
        let html = await response.text();
        html = minify(html);
        return new Response(html, {
          status: response.status,
          headers: response.headers,
        });
      }
    
      return response;
    });

    You can now add your integration's middleware and specify that it runs either before or after the application's own defined middleware (defined in src/middleware.{js,ts})

    // my-package/integration.js
    export function myIntegration() {
      return {
        name: 'my-integration',
        hooks: {
          'astro:config:setup': ({ addMiddleware }) => {
            addMiddleware({
              entrypoint: 'my-package/middleware',
              order: 'pre',
            });
          },
        },
      };
    }
  • #​8854 3e1239e42 Thanks @​natemoo-re! - Provides a new, experimental build cache for Content Collections as part of the Incremental Build RFC. This includes multiple refactors to Astro's build process to optimize how Content Collections are handled, which should provide significant performance improvements for users with many collections.

    Users building a static site can opt-in to preview the new build cache by adding the following flag to your Astro config:

    // astro.config.mjs
    export default {
      experimental: {
        contentCollectionCache: true,
      },
    };

    When this experimental feature is enabled, the files generated from your content collections will be stored in the cacheDir (by default, node_modules/.astro) and reused between builds. Most CI environments automatically restore files in node_modules/ by default.

    In our internal testing on the real world Astro Docs project, this feature reduces the bundling step of astro build from 133.20s to 10.46s, about 92% faster. The end-to-end astro build process used to take 4min 58s and now takes just over 1min for a total reduction of 80%.

    If you run into any issues with this experimental feature, please let us know!

    You can always bypass the cache for a single build by passing the --force flag to astro build.

    astro build --force
    
  • #​8963 fda3a0213 Thanks @​matthewp! - Form support in View Transitions router

    The <ViewTransitions /> router can now handle form submissions, allowing the same animated transitions and stateful UI retention on form posts that are already available on <a> links. With this addition, your Astro project can have animations in all of these scenarios:

    • Clicking links between pages.
    • Making stateful changes in forms (e.g. updating site preferences).
    • Manually triggering navigation via the navigate() API.

    This feature is opt-in for semver reasons and can be enabled by adding the handleForms prop to the ` component:

v3.4.4

Compare Source

Patch Changes

v3.4.3

Compare Source

Patch Changes

v3.4.2

Compare Source

Patch Changes

v3.4.1

Compare Source

Patch Changes

v3.4.0

Compare Source

Minor Changes
  • #​8755 fe4079f05 Thanks @​matthewp! - Page Partials

    A page component can now be identified as a partial page, which will render its HTML content without including a <! DOCTYPE html> declaration nor any <head> content.

    A rendering library, like htmx or Stimulus or even just jQuery can access partial content on the client to dynamically update only parts of a page.

    Pages marked as partials do not have a doctype or any head content included in the rendered result. You can mark any page as a partial by setting this option:

v3.3.4

Compare Source

Patch Changes

v3.3.3

Compare Source

Patch Changes

v3.3.2

Compare Source

Patch Changes

v3.3.1

Compare Source

Patch Changes

v3.3.0

Compare Source

Minor Changes
  • #​8808 2993055be Thanks @​delucis! - Adds support for an --outDir CLI flag to astro build

  • #​8502 c4270e476 Thanks @​bluwy! - Updates the internal shiki syntax highlighter to shikiji, an ESM-focused alternative that simplifies bundling and maintenance.

    There are no new options and no changes to how you author code blocks and syntax highlighting.

    Potentially breaking change: While this refactor should be transparent for most projects, the transition to shikiji now produces a smaller HTML markup by attaching a fallback color style to the pre or code element, instead of to the line span directly. For example:

    Before:

    <code class="astro-code" style="background-color: #&#8203;24292e">
      <pre>
        <span class="line" style="color: #e1e4e8">my code</span>
      </pre>
    </code>

    After:

    <code class="astro-code" style="background-color: #&#8203;24292e; color: #e1e4e8">
      <pre>
        <span class="line">my code<span>
      </pre>
    </code>

    This does not affect the colors as the span will inherit the color from the parent, but if you're relying on a specific HTML markup, please check your site carefully after upgrading to verify the styles.

  • #​8798 f369fa250 Thanks @​Princesseuh! - Fixed tsconfig.json's new array format for extends not working. This was done by migrating Astro to use tsconfck instead of tsconfig-resolver to find and parse tsconfig.json files.

  • #​8620 b2ae9ee0c Thanks @​Princesseuh! - Adds experimental support for generating srcset attributes and a new <Picture /> component.

v3.2.4

Compare Source

Patch Changes

v3.2.3

Compare Source

Patch Changes

[v3.2.2](https://togithub.com/withastro/astro/blob/HE


Configuration

📅 Schedule: Branch creation - "before 4am on Monday" (UTC), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about these updates again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate. View repository job log here.

@renovate renovate bot added the dependencies Update of project's dependencies label May 6, 2024
Copy link
Contributor Author

renovate bot commented May 6, 2024

⚠ Artifact update problem

Renovate failed to update an artifact related to this branch. You probably do not want to merge this PR as-is.

♻ Renovate will retry this branch, including artifacts, only when one of the following happens:

  • any of the package files in this branch needs updating, or
  • the branch becomes conflicted, or
  • you click the rebase/retry checkbox if found above, or
  • you rename this PR's title to start with "rebase!" to trigger it manually

The artifact failure details are included below:

File name: package-lock.json
npm error code ERESOLVE
npm error ERESOLVE could not resolve
npm error
npm error While resolving: @astrojs/image@0.17.2
npm error Found: astro@3.6.5
npm error node_modules/astro
npm error   dev astro@"3.6.5" from the root project
npm error
npm error Could not resolve dependency:
npm error peer astro@"^2.7.3" from @astrojs/image@0.17.2
npm error node_modules/@astrojs/image
npm error   dev @astrojs/image@"0.17.2" from the root project
npm error
npm error Conflicting peer dependency: astro@2.10.15
npm error node_modules/astro
npm error   peer astro@"^2.7.3" from @astrojs/image@0.17.2
npm error   node_modules/@astrojs/image
npm error     dev @astrojs/image@"0.17.2" from the root project
npm error
npm error Fix the upstream dependency conflict, or retry
npm error this command with --force or --legacy-peer-deps
npm error to accept an incorrect (and potentially broken) dependency resolution.
npm error
npm error
npm error For a full report see:
npm error /tmp/renovate/cache/others/npm/_logs/2024-05-06T03_55_27_939Z-eresolve-report.txt

npm error A complete log of this run can be found in: /tmp/renovate/cache/others/npm/_logs/2024-05-06T03_55_27_939Z-debug-0.log

Copy link
Contributor Author

renovate bot commented May 6, 2024

Edited/Blocked Notification

Renovate will not automatically rebase this PR, because it does not recognize the last commit author and assumes somebody else may have edited the PR.

You can manually request rebase by checking the rebase/retry box above.

⚠️ Warning: custom changes will be lost.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Update of project's dependencies
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

0 participants