Packages

@astrojs/preact

6.1.6 · 13 Nov 2026MIT267k / weekRepositoryHomepagenpmAtom feed

Your version

82 stable releases, newest first, by release line. Notes are quoted as the maintainers published them.

  1. 6.x · latest line
  2. 6.1.6

    13 Nov 2026
    • Unpins @astrojs/* dependencies to allow versions matching the ^ range to be installed

  3. 6.1.2 – 6.1.54 releases that only update dependencies@astrojs/preact-renderer 0.1.2@astrojs/internal-helpers 0.13.2Show each
  4. 6.1.1

    21 Oct 2026
  5. 6.1.0

    15 Oct 2026
    • Breaking

      Increases the minimum Node.js version to 22.22.0

      The minimum supported Node.js version is now 22.22.0, the latest Node.js 22 release supported by StackBlitz. This change is in line with Astro's Node.js support policy.

    • Adds support for Preact v11

  6. 6.0.1 – 6.0.66 releases that only update dependencies@astrojs/internal-helpers 0.12.0Show each
  7. 6.0.0

    22 Jun 2026
    • Breaking

      Upgrade to Vite v8

    • Replaces the import entrypoint of getContainerRenderer()

      A new container-renderer entrypoint exporting getContainerRenderer() has been added to the following integrations: React, Preact, Svelte, SolidJS, Vue, and MDX. This prevents bundlers from trying to bundle unrelated exports from the package root when only the Container API is used.

      If you are using the Container API, update your import statements to use the new entrypoint. The following example updates the getContainerRenderer() import for React:

      - import { getContainerRenderer } from '@astrojs/react';
      + import { getContainerRenderer } from '@astrojs/react/container-renderer';

      Importing getContainerRenderer() from the package root still works, but is now deprecated and logs a warning.

    • Triggers beta prereleases for packages that are still on alpha

  8. 5.x
  9. 5.1.5

    2 Jun 2026
    • Bumps devalue dependency to v5.8.1

  10. 5.1.2 – 5.1.43 releases that only update dependencies@astrojs/internal-helpers 0.10.0Show each
  11. 5.1.1

    1 Apr 2026
    • Pre-optimizes @preact/signals and preact/hooks in the Vite dep optimizer to prevent late discovery triggering full page reloads during dev

  12. 5.1.0

    26 Mar 2026
    • Adds support for passing a Babel config to the Preact Vite Plugin:

      // astro.config.mjs
      import { defineConfig } from 'astro/config';
      import preact from '@astrojs/preact';
      
      export default defineConfig({
        integrations: [
          preact({
            babel: {
              generatorOpts: {
                importAttributesKeyword: 'with',
              },
            },
          }),
        ],
      });
  13. 5.0.2

    18 Mar 2026
    • Removes temporary support for Node >=20.19.1 because Stackblitz now uses Node 22 by default

  14. 5.0.1

    16 Mar 2026
    • Fix useId() collisions across multiple Astro islands by seeding a unique per-island root mask for Preact SSR and hydration.

  15. 5.0.0

    10 Mar 2026
    • Breaking

      Increases minimum Node.js version to 22.12.0 - (v6 upgrade guidance)

    • Breaking

      Astro v6.0 upgrades to Vite v7.0 as the development server and production bundler - (v6 upgrade guidance)

    • Update to Astro 6 beta

  16. 4.x
  17. 4.1.3

    6 Nov 2025
    • Adds support for client hydration in getContainerRenderer()

      The getContainerRenderer() function is exported by Astro framework integrations to simplify the process of rendering framework components when using the experimental Container API inside a Vite or Vitest environment. This update adds the client hydration entrypoint to the returned object, enabling client-side interactivity for components rendered using this function. Previously this required users to manually call container.addClientRenderer() with the appropriate client renderer entrypoint.

      See the container-with-vitest demo for a usage example, and the Container API documentation for more information on using framework components with the experimental Container API.

  18. 4.1.2

    28 Oct 2025
    • Updates vite version to fix CVE

  19. 4.1.1

    8 Sep 2025
    • Updates vite version to fix CVE

  20. 4.1.0

    22 May 2025
    • Breaking

      Increases minimum Node.js version to 18.20.8

      Node.js 18 has now reached end-of-life and should not be used. For now, Astro will continue to support Node.js 18.20.8, which is the final LTS release of Node.js 18, as well as Node.js 20 and Node.js 22 or later. We will drop support for Node.js 18 in a future release, so we recommend upgrading to Node.js 22 as soon as possible. See Astro's Node.js support policy for more details.

      :warning: Important note for users of Cloudflare Pages: The current build image for Cloudflare Pages uses Node.js 18.17.1 by default, which is no longer supported by Astro. If you are using Cloudflare Pages you should override the default Node.js version to Node.js 22. This does not affect users of Cloudflare Workers, which uses Node.js 22 by default.

  21. 4.0.11

    30 Apr 2025
    • Update vite to latest version for fixing CVE

  22. 4.0.10

    23 Apr 2025
    • Removes unused code

  23. 4.0.9

    14 Apr 2025
    • Update vite to latest version to fix CVE

    • Updates vite to the latest version

  24. 4.0.8

    31 Mar 2025
    • Update vite to the latest version

  25. 4.0.7

    26 Mar 2025
    • Updates the dependency vite to the latest.

  26. 4.0.6

    21 Mar 2025
    • Hides fallback content when rendering client:only island

  27. 4.0.5

    27 Feb 2025
    • Updates esbuild and vite to the latest to avoid false positives audits warnings caused by esbuild.

  28. 4.0.4

    4 Feb 2025
  29. 4.0.3

    20 Jan 2025
    • Upgrades Vite

  30. 4.0.2

    15 Jan 2025
    • Adds a warning message when multiple JSX-based UI frameworks are being used without either the include or exclude property being set on the integration.

  31. 4.0.1

    20 Dec 2024
    • Upgrades Vite to pin esbuild

  32. 4.0.0

    3 Dec 2024
    • Breaking

      Updates Vite dependency to v6 to match Astro v5

    • Removed

      Drops node 21 support

  33. 3.x
  34. 3.5.4

    21 Nov 2024
    • Resolve vite peer dependency problem for strict package managers like Yarn in PnP mode.

  35. 3.5.3

    6 Sep 2024
    • Preact components no longer throw an error if a property is null.

  36. 3.5.2

    28 Aug 2024
    • Preact signals are now serialized correctly in arrays when they are given to components.

  37. 3.5.1

    17 Jul 2024
    • Swap out preact-ssr-prepass for renderToStringAsync from preact-render-to-string

  38. 3.5.0

    17 Jun 2024
    • Adds a new function called addServerRenderer to 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);
      };
  39. 3.4.0

    6 Jun 2024
    • The integration now exposes a function called getContainerRenderer, 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');
      });
  40. 3.3.0

    9 May 2024
    • Adds a devtools option

      You can enable Preact devtools in development by setting devtools: true in your preact() integration config:

      import { defineConfig } from 'astro/config';
      import preact from '@astrojs/preact';
      
      export default defineConfig({
        integrations: [preact({ devtools: true })],
      });
  41. 3.2.0

    11 Apr 2024
    • Deprecated

      Deprecate support for versions of Node.js older than v18.17.1 for Node.js 18, older than v20.0.3 for Node.js 20, and the complete Node.js v19 release line.

      This change is in line with Astro's Node.js support policy.

  42. 3.1.2

    2 Apr 2024
    • Fixes (theoretical) edge case in Preact integration's JSX aliases

  43. 3.1.1

    22 Feb 2024
    • Fixes passing children to server-rendered components causing an error

  44. 3.1.0

    4 Jan 2024
    • 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>
        );
      };

A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.