diff --git a/packages/plugin-react/CHANGELOG.md b/packages/plugin-react/CHANGELOG.md index 0421878eb..7b05d2591 100644 --- a/packages/plugin-react/CHANGELOG.md +++ b/packages/plugin-react/CHANGELOG.md @@ -2,6 +2,25 @@ ## Unreleased +### Add experimental native React Compiler support ([#1419](https://github.com/vitejs/vite-plugin-react/pull/1419)) + +Add experimental native React Compiler support. + +You can use it by installing `oxc-transform-react` and enabling it via the `compiler` option: +```sh +npm install -D oxc-transform-react +``` +```js +import { defineConfig } from 'vite' +import react from '@vitejs/plugin-react' + +export default defineConfig({ + plugins: [ + react({ compiler: true }) + ] +}) +``` + ## 6.0.5 (2026-07-30) ### Fixed the react compiler preset filter to be linear ([#1353](https://github.com/vitejs/vite-plugin-react/pull/1353)) diff --git a/packages/plugin-react/README.md b/packages/plugin-react/README.md index 563a81142..1799fc321 100644 --- a/packages/plugin-react/README.md +++ b/packages/plugin-react/README.md @@ -79,13 +79,42 @@ Under the hood, this simply updates the React Fash Refresh runtime URL from `/@r ## React Compiler -[React Compiler](https://react.dev/learn/react-compiler) support is available via the exported `reactCompilerPreset` helper, which requires [`@rolldown/plugin-babel`](https://npmx.dev/package/@rolldown/plugin-babel) and [`babel-plugin-react-compiler`](https://npmx.dev/package/babel-plugin-react-compiler) and [`@babel/core`](https://npmx.dev/package/@babel/core) as peer dependencies: +### Rust React Compiler + +> [!WARNING] +> Native React Compiler support is experimental. + +The `compiler` option uses [`oxc-transform-react`](https://npmx.dev/package/oxc-transform-react), a Rust port of [React Compiler](https://react.dev/learn/react-compiler), which must be installed as an optional peer dependency: + +```sh +npm install -D oxc-transform-react +``` + +```js +// vite.config.js +import { defineConfig } from 'vite' +import react from '@vitejs/plugin-react' + +export default defineConfig({ + plugins: [react({ compiler: true })], +}) +``` + +The `compiler` option also accepts [React Compiler options](https://react.dev/reference/react-compiler/configuration): + +```js +react({ compiler: { compilationMode: 'annotation' } }) +``` + +### Babel React Compiler + +React Compiler can also be used through Babel with the exported `reactCompilerPreset` helper. This requires [`@rolldown/plugin-babel`](https://npmx.dev/package/@rolldown/plugin-babel), [`babel-plugin-react-compiler`](https://npmx.dev/package/babel-plugin-react-compiler), and [`@babel/core`](https://npmx.dev/package/@babel/core) as peer dependencies: ```sh npm install -D @rolldown/plugin-babel @babel/core babel-plugin-react-compiler ``` -If you are using TypeScript, you will also need to install [`@types/babel__core`](https://npmx.dev/package/@types/babel__core): +If you are using TypeScript with Babel 7, you will also need to install [`@types/babel__core`](https://npmx.dev/package/@types/babel__core): ```sh npm install -D @types/babel__core diff --git a/packages/plugin-react/package.json b/packages/plugin-react/package.json index bb838ba24..e1a70071d 100644 --- a/packages/plugin-react/package.json +++ b/packages/plugin-react/package.json @@ -50,6 +50,7 @@ "@rolldown/plugin-babel": "^0.2.3", "@vitejs/react-common": "workspace:*", "babel-plugin-react-compiler": "^1.0.0", + "oxc-transform-react": "^0.145.0", "react": "^19.2.8", "react-dom": "^19.2.8", "rolldown": "^1.2.3", @@ -59,6 +60,7 @@ "peerDependencies": { "@rolldown/plugin-babel": "^0.1.7 || ^0.2.0", "babel-plugin-react-compiler": "^1.0.0", + "oxc-transform-react": "^0.145.0", "vite": "^8.0.0" }, "peerDependenciesMeta": { @@ -67,6 +69,9 @@ }, "babel-plugin-react-compiler": { "optional": true + }, + "oxc-transform-react": { + "optional": true } }, "engines": { diff --git a/packages/plugin-react/src/index.ts b/packages/plugin-react/src/index.ts index 9a9019b31..b86d7c37b 100644 --- a/packages/plugin-react/src/index.ts +++ b/packages/plugin-react/src/index.ts @@ -14,7 +14,8 @@ import { } from '@vitejs/react-common' import type { Plugin, ServerOptions } from 'vite' import { reactRefreshWrapperPlugin } from 'vite/internal' -import { reactCompilerPreset } from './reactCompilerPreset' +import type { ReactCompilerOptions } from '#optionalTypes' +import { defaultCodeFilter, reactCompilerPreset } from './reactCompilerPreset' const _dirname = dirname(fileURLToPath(import.meta.url)) const refreshRuntimePath = join(_dirname, 'refresh-runtime.js') @@ -52,6 +53,13 @@ export interface Options { * reactRefreshHost: 'http://localhost:3000' */ reactRefreshHost?: string + /** + * Enable React Compiler with its default options or configure it. + * This requires `oxc-transform-react` to be installed. + * @default false + * @experimental + */ + compiler?: boolean | ReactCompilerOptions } const defaultIncludeRE = /\.[tj]sx?$/ @@ -82,12 +90,13 @@ export default function viteReact(opts: Options = {}): Plugin[] { name: 'vite:react-babel', enforce: 'pre', config(_userConfig, { command }) { + const refresh = command === 'serve' && !opts.compiler if (opts.jsxRuntime === 'classic') { return { oxc: { jsx: { runtime: 'classic', - refresh: command === 'serve', + refresh, }, jsxRefreshInclude: makeIdFiltersToMatchWithQuery(include), jsxRefreshExclude: makeIdFiltersToMatchWithQuery(exclude), @@ -99,7 +108,7 @@ export default function viteReact(opts: Options = {}): Plugin[] { jsx: { runtime: 'automatic', importSource: opts.jsxImportSource, - refresh: command === 'serve', + refresh, }, jsxRefreshInclude: makeIdFiltersToMatchWithQuery(include), jsxRefreshExclude: makeIdFiltersToMatchWithQuery(exclude), @@ -251,7 +260,7 @@ export default function viteReact(opts: Options = {}): Plugin[] { }, } - return [ + const plugins = [ viteBabel, viteRefreshWrapper, viteConfigPost, @@ -262,11 +271,120 @@ export default function viteReact(opts: Options = {}): Plugin[] { isEnabled: () => !skipFastRefresh && !isBundledDev, }), ] + + if (opts.compiler) { + plugins.unshift( + createReactCompilerPlugin( + opts.compiler === true ? {} : opts.compiler, + include, + exclude, + opts, + () => !skipFastRefresh, + ), + ) + } + + return plugins +} + +function createReactCompilerPlugin( + options: ReactCompilerOptions, + include: NonNullable, + exclude: NonNullable, + reactOptions: Pick, + isFastRefreshEnabled: () => boolean, +): Plugin { + let sourcemap = true + let jsxDevelopment = false + let compiler: typeof import('oxc-transform-react') | undefined + const runtime = + options.target === '17' || options.target === '18' + ? 'react-compiler-runtime' + : 'react/compiler-runtime' + + const loadCompiler = async ( + onError: (message: string) => never, + ): Promise => { + if (compiler) return compiler + + try { + return (compiler = await import('oxc-transform-react')) + } catch (error) { + return onError( + `React Compiler requires the optional \`oxc-transform-react\` package. Install it in your project before enabling \`react({ compiler: true })\`.${ + error instanceof Error ? `\n${error.message}` : '' + }`, + ) + } + } + + return { + name: 'vite:react-compiler', + enforce: 'pre', + async config() { + await loadCompiler((message) => this.error(message)) + return { + optimizeDeps: { + include: [runtime], + }, + } + }, + configResolved(config) { + sourcemap = config.command !== 'build' || !!config.build.sourcemap + jsxDevelopment = !config.isProduction + }, + transform: { + filter: { + id: { + include: makeIdFiltersToMatchWithQuery(include), + exclude: makeIdFiltersToMatchWithQuery(exclude), + }, + }, + async handler(code, id) { + const isClient = this.environment?.config.consumer !== 'server' + const shouldCompile = + isClient && + (options.compilationMode === 'annotation' + ? /['"]use memo['"]/.test(code) + : defaultCodeFilter.test(code)) + // The config hook is not called when the plugin is used with Rolldown directly. + const { transform } = + compiler ?? (await loadCompiler((message) => this.error(message))) + + const result = await transform(id.split('?')[0]!, code, { + jsx: { + runtime: reactOptions.jsxRuntime, + development: jsxDevelopment, + importSource: reactOptions.jsxImportSource, + refresh: isClient && isFastRefreshEnabled(), + }, + reactCompiler: shouldCompile ? options : false, + sourcemap, + }) + const diagnostics = result.errors.map( + (error) => + `${error.message}${error.codeframe ? `\n${error.codeframe}` : ''}`, + ) + + if (result.fatal) { + this.error( + diagnostics.join('\n\n') || 'React Compiler transform failed.', + ) + } + for (const diagnostic of diagnostics) { + this.warn(diagnostic) + } + + return { code: result.code, map: result.map } + }, + }, + } } viteReact.preambleCode = preambleCode export { reactCompilerPreset } +export type { ReactCompilerOptions } // Compat for require function viteReactForCjs(this: unknown, options: Options): Plugin[] { diff --git a/packages/plugin-react/tests/reactCompiler.test.ts b/packages/plugin-react/tests/reactCompiler.test.ts new file mode 100644 index 000000000..fd7abbd2b --- /dev/null +++ b/packages/plugin-react/tests/reactCompiler.test.ts @@ -0,0 +1,191 @@ +import path from 'node:path' +import { type Plugin, rolldown } from 'rolldown' +import { describe, expect, test } from 'vitest' +import pluginReact, { + type Options, + type ReactCompilerOptions, +} from '../src/index.ts' + +describe('compiler option', () => { + test('compiles React components', async () => { + const output = await bundle( + { compiler: true }, + ` + export function App({ name }: { name: string }) { + return
{name}
+ } + `, + ) + + expect(output.code).toContain('react/compiler-runtime') + expect(output.code).toMatch(/\bc\(2\)/) + expect( + output.map?.sources.some((source) => source.endsWith('entry.tsx')), + ).toBe(true) + }) + + test('forwards compiler options', async () => { + const code = ` + export function App({ name }) { + return
{name}
+ } + ` + const unannotated = await bundle( + { compiler: { compilationMode: 'annotation' } }, + code, + ) + const annotated = await bundle( + { compiler: { compilationMode: 'annotation' } }, + ` + export function App({ name }) { + 'use memo' + return
{name}
+ } + `, + ) + const react18 = await bundle({ compiler: { target: '18' } }, code) + + expect(unannotated.code).not.toContain('react/compiler-runtime') + expect(annotated.code).toContain('react/compiler-runtime') + expect(react18.code).toContain('react-compiler-runtime') + }) + + test('uses the React plugin filters', async () => { + const excluded = await bundle( + { compiler: true, exclude: /entry\.tsx$/ }, + `export function App({ name }) { return
{name}
}`, + ) + const codeFiltered = await bundle( + { compiler: true }, + `export const element =
`, + ) + + expect(excluded.code).not.toContain('react/compiler-runtime') + expect(excluded.code).toContain('react/jsx-runtime') + expect(excluded.code).not.toContain(' { + expect(await getViteReactConfig({ compiler: true }, 'serve')).toMatchObject( + { + oxc: { + jsx: { + runtime: 'automatic', + refresh: false, + }, + }, + }, + ) + expect(await getViteReactConfig({}, 'serve')).toMatchObject({ + oxc: { + jsx: { + runtime: 'automatic', + refresh: true, + }, + }, + }) + }) + + test('uses the native JSX transform for server environments', async () => { + const output = await transformWithBuildConfig({}, false, 'server') + + expect(output.code).toContain('react/jsx-runtime') + expect(output.code).not.toContain('react/compiler-runtime') + }) + + test('uses the Vite build sourcemap setting', async () => { + const withoutSourcemap = await transformWithBuildConfig({}, false) + expect(withoutSourcemap.code).toContain('react/jsx-runtime') + expect(withoutSourcemap.map).toBeFalsy() + expect((await transformWithBuildConfig({}, true)).map).toBeTruthy() + }) +}) + +async function transformWithBuildConfig( + compiler: ReactCompilerOptions, + buildSourcemap: boolean, + consumer: 'client' | 'server' = 'client', +) { + const plugin = pluginReact({ compiler }).find( + (plugin) => plugin.name === 'vite:react-compiler', + )! + const context = { + error(message: unknown): never { + throw new Error(String(message)) + }, + warn() {}, + environment: { config: { consumer } }, + } + + if (typeof plugin.config !== 'function') + throw new Error('Missing config hook') + await plugin.config.call( + context as any, + {}, + { command: 'build', mode: 'production' }, + ) + + if (typeof plugin.configResolved !== 'function') { + throw new Error('Missing configResolved hook') + } + await plugin.configResolved.call( + context as any, + { + command: 'build', + isProduction: true, + build: { sourcemap: buildSourcemap }, + } as any, + ) + + if (typeof plugin.transform !== 'object') { + throw new Error('Missing transform hook') + } + return plugin.transform.handler.call( + context as any, + `export function App({ name }) { return
{name}
}`, + '/entry.tsx', + ) +} + +async function getViteReactConfig( + options: Options, + command: 'serve' | 'build', +) { + const plugin = pluginReact(options).find( + (plugin) => plugin.name === 'vite:react-babel', + )! + + if (typeof plugin.config !== 'function') + throw new Error('Missing config hook') + return plugin.config.call( + {} as any, + {}, + { command, mode: command === 'serve' ? 'development' : 'production' }, + ) +} + +async function bundle(options: Options, code: string) { + const entry = '/entry.tsx' + const build = await rolldown({ + input: entry, + plugins: [virtualFilePlugin(entry, code), pluginReact(options)], + external: [/^react(\/|$)/, /^react-compiler-runtime$/], + }) + const { output } = await build.generate({ format: 'esm', sourcemap: true }) + return output[0] +} + +function virtualFilePlugin(entry: string, code: string): Plugin { + return { + name: 'virtual-file', + resolveId(id, importer) { + const baseDir = importer ? path.posix.dirname(importer) : '/' + if (path.posix.resolve(baseDir, id) === entry) return entry + }, + load(id) { + if (id === entry) return code + }, + } +} diff --git a/packages/plugin-react/types/optionalTypes.d.ts b/packages/plugin-react/types/optionalTypes.d.ts index f780e933f..e8c36cf6b 100644 --- a/packages/plugin-react/types/optionalTypes.d.ts +++ b/packages/plugin-react/types/optionalTypes.d.ts @@ -4,9 +4,13 @@ import type * as pluginBabel from '@rolldown/plugin-babel' // @ts-ignore --- `babel-plugin-react-compiler` is an optional peer dependency, so this may cause an error import type * as babelPluginReactCompiler from 'babel-plugin-react-compiler' +// @ts-ignore --- `oxc-transform-react` is an optional peer dependency, so this may cause an error +import type * as oxcTransformReact from 'oxc-transform-react' // @ts-ignore --- `@rolldown/plugin-babel` is an optional peer dependency, so this may cause an error export type RolldownBabelPreset = pluginBabel.RolldownBabelPreset // @ts-ignore --- `babel-plugin-react-compiler` is an optional peer dependency, so this may cause an error export type ReactCompilerBabelPluginOptions = babelPluginReactCompiler.PluginOptions +// @ts-ignore --- `oxc-transform-react` is an optional peer dependency, so this may cause an error +export type ReactCompilerOptions = oxcTransformReact.ReactCompilerOptions diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f560b3b5e..ee45ec1ac 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -90,6 +90,9 @@ importers: babel-plugin-react-compiler: specifier: ^1.0.0 version: 1.0.0 + oxc-transform-react: + specifier: ^0.145.0 + version: 0.145.0 react: specifier: ^19.2.8 version: 19.2.8 @@ -2125,6 +2128,128 @@ packages: '@oxc-project/types@0.143.0': resolution: {integrity: sha512-u6JZdLBTLotrNC9Vd6vPssINdzcCzleKAH6EJKImQb7GtYvX5keN2dxkoK44stCc4tffE6QQRtZTXVSzsLUlWA==} + '@oxc-transform-react/binding-android-arm-eabi@0.145.0': + resolution: {integrity: sha512-KuK3zAp10yFyeAxIXlZn2ycsFpaKLxUmj5BVRS1io4XfwnKTozb/goZakgKD5JEiHOVOtEKt1r7pTrmW/pFxxA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm] + os: [android] + + '@oxc-transform-react/binding-android-arm64@0.145.0': + resolution: {integrity: sha512-eDUKx6MAgRAF67JPScjLF6h8lL2qmlvFrXGSG8mYFIVJb++NMyDygiIo8TAKdWQNguoBElUZw/SK2EPRaKsryQ==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [android] + + '@oxc-transform-react/binding-darwin-arm64@0.145.0': + resolution: {integrity: sha512-msCgwbVLswJ08JaUOjfPddieVJwE4IT1Y23A1DDyKVyzZp2ormo9a4ffDEu9nmmovdEj8VqAyFgggsgzIkBVrA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [darwin] + + '@oxc-transform-react/binding-darwin-x64@0.145.0': + resolution: {integrity: sha512-R0PtsoOCsARulmWhLG1fFInT+98TRl/H6w6ifi8XOLvpdsksD1rxsw4Ol84lHbdHCcMNjfJTckZzQIZBMiXkLg==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [x64] + os: [darwin] + + '@oxc-transform-react/binding-freebsd-x64@0.145.0': + resolution: {integrity: sha512-/MJ7+IvxfutSGqn6hIXU92wGNk5FlkqbTHM+kEl7ytLLOSAyivYhF2gxdYMmXTwOG56k2XviMcE0D/TBjdyoRA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [x64] + os: [freebsd] + + '@oxc-transform-react/binding-linux-arm-gnueabihf@0.145.0': + resolution: {integrity: sha512-ssHZ0W2wSjQwaBQdkg8u+A7dTdw2vkGSK0hRfCoDCkRkETu+19Q8Tae7NNxlYHcP1iUQYhEj8Qfgpq+S/MdrYA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm] + os: [linux] + + '@oxc-transform-react/binding-linux-arm-musleabihf@0.145.0': + resolution: {integrity: sha512-adJy4lQVcoIW6CUzQYbDgbHZMDSLoizwCinG2Dex29jdACKwIgXQQrIAHAgfveaZleKIB/rf3usGoRcOGyfz7Q==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm] + os: [linux] + + '@oxc-transform-react/binding-linux-arm64-gnu@0.145.0': + resolution: {integrity: sha512-7KRa0CC1FaSKx5sy+bDtqGvXF+RiVoMmSe8OmTKm9kRZkNVdmsmpnsQhgravehTohlWDveo5aoGMwcFtffGDmw==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [linux] + libc: [glibc] + + '@oxc-transform-react/binding-linux-arm64-musl@0.145.0': + resolution: {integrity: sha512-fGhZkDnk2RoMp6THas9HFGorF0A1wwPPA/2Lu9IUO1ip5MJqS/JG7/conmiz0DBG0PWBtnKl2Y8sA/VBiD/oQw==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [linux] + libc: [musl] + + '@oxc-transform-react/binding-linux-ppc64-gnu@0.145.0': + resolution: {integrity: sha512-VBaUTjRZYRypD2tL7cmbM2Fn6fvTnacLQ1GdsU1Y6A3fkqA/z+wc5Vy1QnnuFe9sIwb9xCvSS2tJVlucR39FYw==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [ppc64] + os: [linux] + libc: [glibc] + + '@oxc-transform-react/binding-linux-riscv64-gnu@0.145.0': + resolution: {integrity: sha512-s2cimMVAmWe9dtjyWdGsYtevi9C7gJoOXwrCZD0BX7hgyGmuBO3iWQjx4W48hdXlWS176NoxuFIHAN72N86upA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [riscv64] + os: [linux] + libc: [glibc] + + '@oxc-transform-react/binding-linux-riscv64-musl@0.145.0': + resolution: {integrity: sha512-hFPrsL2nKL4aa8vFmheR53PcrxQgym8bnaSD1pMX9IoyQq+/ksAuw1CDJSV9c5xhxxZdw/KTPVer7M/6OQvfoA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [riscv64] + os: [linux] + libc: [musl] + + '@oxc-transform-react/binding-linux-s390x-gnu@0.145.0': + resolution: {integrity: sha512-YLKhySqqu0JAtT0z8GuaFF7Hht3IvQLZShTH0DxeV28NwSthva+qJ7GN09ALT1bqRVvMjNGycgPHaGSWBUIt7A==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [s390x] + os: [linux] + libc: [glibc] + + '@oxc-transform-react/binding-linux-x64-gnu@0.145.0': + resolution: {integrity: sha512-WqgJ+0M9mwQ1cRfSgk4vzYudD2imLSBhUZ2QFes06vUjigts5Dw4NajWKc2JibPHYsoiUA9Zj39zWwC5AxXEGQ==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [x64] + os: [linux] + libc: [glibc] + + '@oxc-transform-react/binding-linux-x64-musl@0.145.0': + resolution: {integrity: sha512-eIre/TjGt07IVKoWUrUOkPxN7UKeWxbiGvCywoGLDRe1/2K50MrA2vQahZ8AlW5CLmajOr9ePKrkRzLg1fa0cQ==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [x64] + os: [linux] + libc: [musl] + + '@oxc-transform-react/binding-openharmony-arm64@0.145.0': + resolution: {integrity: sha512-zhWiyJ+9XD4cuhSZIT6aozuXDHcZHNdoVe88xVmx2XN00anjZ6VAGj31rhD8ndha/F8NllcQEr8Q61Dr2MHv5Q==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [openharmony] + + '@oxc-transform-react/binding-win32-arm64-msvc@0.145.0': + resolution: {integrity: sha512-Q0oiZfrfYyhmpqH2K0dylDTooIadecGsoiQks7G0AbuszCu2I7zYyJo4ArFc3d5Hj49Jjc5dDAE5WP/Sg2p8hw==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [arm64] + os: [win32] + + '@oxc-transform-react/binding-win32-ia32-msvc@0.145.0': + resolution: {integrity: sha512-ERpriVJY5S8hXd3BJi4UtzsIVsEQnntmpqTgRqh0XCaflLRLTQnPWpkO8rgtI7xye5MRhfhA+qsxKg2olJs4qA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [ia32] + os: [win32] + + '@oxc-transform-react/binding-win32-x64-msvc@0.145.0': + resolution: {integrity: sha512-sa781BGPLDw8+7ATrgUpLr0f4t0Q14O+zk3fOuQbUpjW5jERc9a3k1xIYKX1JkTG/sszoFhi8LzyCoMC49tkWA==} + engines: {node: ^20.19.0 || >=22.12.0} + cpu: [x64] + os: [win32] + '@oxfmt/binding-android-arm-eabi@0.62.0': resolution: {integrity: sha512-pdsv0C4gPjJ8H1+sd8u0BDx+yLACTL+rgeMIOL1ln4ihSnhw8CWXtYWgvcSkyTfgGBIzFKab+d8rx9Xl4en/Kw==} engines: {node: ^20.19.0 || >=22.12.0} @@ -4191,6 +4316,10 @@ packages: resolution: {integrity: sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg==} engines: {node: '>= 0.8.0'} + oxc-transform-react@0.145.0: + resolution: {integrity: sha512-y8cfjow11WKvDekonySPVvRUvNuIvqNT0LZ0Aey6j5dsNUD6k4hy6Mae/SLmng5egmb1GdJS11GduJ+IoEAXEw==} + engines: {node: ^20.19.0 || >=22.12.0} + oxfmt@0.62.0: resolution: {integrity: sha512-vxgGHTmnDU9j4CX7dDBLzxgmHxfda/yPcgJkGCMUSCwRmz+euo/V08xXLNgXTeqAB9Fhf3Pe2nO1RNKLCVgphQ==} engines: {node: ^20.19.0 || >=22.12.0} @@ -5626,6 +5755,63 @@ snapshots: '@oxc-project/types@0.143.0': {} + '@oxc-transform-react/binding-android-arm-eabi@0.145.0': + optional: true + + '@oxc-transform-react/binding-android-arm64@0.145.0': + optional: true + + '@oxc-transform-react/binding-darwin-arm64@0.145.0': + optional: true + + '@oxc-transform-react/binding-darwin-x64@0.145.0': + optional: true + + '@oxc-transform-react/binding-freebsd-x64@0.145.0': + optional: true + + '@oxc-transform-react/binding-linux-arm-gnueabihf@0.145.0': + optional: true + + '@oxc-transform-react/binding-linux-arm-musleabihf@0.145.0': + optional: true + + '@oxc-transform-react/binding-linux-arm64-gnu@0.145.0': + optional: true + + '@oxc-transform-react/binding-linux-arm64-musl@0.145.0': + optional: true + + '@oxc-transform-react/binding-linux-ppc64-gnu@0.145.0': + optional: true + + '@oxc-transform-react/binding-linux-riscv64-gnu@0.145.0': + optional: true + + '@oxc-transform-react/binding-linux-riscv64-musl@0.145.0': + optional: true + + '@oxc-transform-react/binding-linux-s390x-gnu@0.145.0': + optional: true + + '@oxc-transform-react/binding-linux-x64-gnu@0.145.0': + optional: true + + '@oxc-transform-react/binding-linux-x64-musl@0.145.0': + optional: true + + '@oxc-transform-react/binding-openharmony-arm64@0.145.0': + optional: true + + '@oxc-transform-react/binding-win32-arm64-msvc@0.145.0': + optional: true + + '@oxc-transform-react/binding-win32-ia32-msvc@0.145.0': + optional: true + + '@oxc-transform-react/binding-win32-x64-msvc@0.145.0': + optional: true + '@oxfmt/binding-android-arm-eabi@0.62.0': optional: true @@ -7602,6 +7788,28 @@ snapshots: prelude-ls: 1.2.1 type-check: 0.4.0 + oxc-transform-react@0.145.0: + optionalDependencies: + '@oxc-transform-react/binding-android-arm-eabi': 0.145.0 + '@oxc-transform-react/binding-android-arm64': 0.145.0 + '@oxc-transform-react/binding-darwin-arm64': 0.145.0 + '@oxc-transform-react/binding-darwin-x64': 0.145.0 + '@oxc-transform-react/binding-freebsd-x64': 0.145.0 + '@oxc-transform-react/binding-linux-arm-gnueabihf': 0.145.0 + '@oxc-transform-react/binding-linux-arm-musleabihf': 0.145.0 + '@oxc-transform-react/binding-linux-arm64-gnu': 0.145.0 + '@oxc-transform-react/binding-linux-arm64-musl': 0.145.0 + '@oxc-transform-react/binding-linux-ppc64-gnu': 0.145.0 + '@oxc-transform-react/binding-linux-riscv64-gnu': 0.145.0 + '@oxc-transform-react/binding-linux-riscv64-musl': 0.145.0 + '@oxc-transform-react/binding-linux-s390x-gnu': 0.145.0 + '@oxc-transform-react/binding-linux-x64-gnu': 0.145.0 + '@oxc-transform-react/binding-linux-x64-musl': 0.145.0 + '@oxc-transform-react/binding-openharmony-arm64': 0.145.0 + '@oxc-transform-react/binding-win32-arm64-msvc': 0.145.0 + '@oxc-transform-react/binding-win32-ia32-msvc': 0.145.0 + '@oxc-transform-react/binding-win32-x64-msvc': 0.145.0 + oxfmt@0.62.0: dependencies: tinypool: 2.1.0