mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-02 02:00:49 +08:00
chore: bump up @vitejs/plugin-react-swc version to v4 (#14405)
This PR contains the following updates: | Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) | |---|---|---|---| | [@vitejs/plugin-react-swc](https://redirect.github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react-swc#readme) ([source](https://redirect.github.com/vitejs/vite-plugin-react/tree/HEAD/packages/plugin-react-swc)) | [`^3.7.2` → `^4.0.0`](https://renovatebot.com/diffs/npm/@vitejs%2fplugin-react-swc/3.9.0/4.2.3) |  |  | --- ### Release Notes <details> <summary>vitejs/vite-plugin-react (@​vitejs/plugin-react-swc)</summary> ### [`v4.2.3`](https://redirect.github.com/vitejs/vite-plugin-react/blob/HEAD/packages/plugin-react-swc/CHANGELOG.md#423-2026-02-02) [Compare Source](https://redirect.github.com/vitejs/vite-plugin-react/compare/5e600a31ec27fae54df58a46ef1fffa80238042e...12914fa8c1d32323db6a134d46cd0ca83db91cd1) ### [`v4.2.2`](https://redirect.github.com/vitejs/vite-plugin-react/blob/HEAD/packages/plugin-react-swc/CHANGELOG.md#422-2025-11-12) [Compare Source](https://redirect.github.com/vitejs/vite-plugin-react/compare/v4.2.1...5e600a31ec27fae54df58a46ef1fffa80238042e) ##### Update code to support newer `rolldown-vite` ([#​978](https://redirect.github.com/vitejs/vite-plugin-react/pull/978)) `rolldown-vite` will remove `optimizeDeps.rollupOptions` in favor of `optimizeDeps.rolldownOptions` soon. This plugin now uses `optimizeDeps.rolldownOptions` to support newer `rolldown-vite`. Please update `rolldown-vite` to the latest version if you are using an older version. ### [`v4.2.1`](https://redirect.github.com/vitejs/vite-plugin-react/blob/HEAD/packages/plugin-react-swc/CHANGELOG.md#421-2025-11-05) [Compare Source](https://redirect.github.com/vitejs/vite-plugin-react/compare/v4.2.0...v4.2.1) ##### Fix `@vitejs/plugin-react-swc/preamble` on build ([#​962](https://redirect.github.com/vitejs/vite-plugin-react/pull/962)) ### [`v4.2.0`](https://redirect.github.com/vitejs/vite-plugin-react/blob/HEAD/packages/plugin-react-swc/CHANGELOG.md#420-2025-10-24) [Compare Source](https://redirect.github.com/vitejs/vite-plugin-react/compare/v4.1.0...v4.2.0) ##### Add `@vitejs/plugin-react-swc/preamble` virtual module for SSR HMR ([#​890](https://redirect.github.com/vitejs/vite-plugin-react/pull/890)) SSR applications can now initialize HMR runtime by importing `@vitejs/plugin-react-swc/preamble` at the top of their client entry instead of manually calling `transformIndexHtml`. This simplifies SSR setup for applications that don't use the `transformIndexHtml` API. ##### Use SWC when useAtYourOwnRisk\_mutateSwcOptions is provided ([#​951](https://redirect.github.com/vitejs/vite-plugin-react/pull/951)) Previously, this plugin did not use SWC if plugins were not provided even if `useAtYourOwnRisk_mutateSwcOptions` was provided. This is now fixed. ### [`v4.1.0`](https://redirect.github.com/vitejs/vite-plugin-react/blob/HEAD/packages/plugin-react-swc/CHANGELOG.md#410-2025-09-17) [Compare Source](https://redirect.github.com/vitejs/vite-plugin-react/compare/f21864b102d40fca4f70dfe9112a10101ec12f54...v4.1.0) ##### Set SWC cacheRoot options This is set to `{viteCacheDir}/swc` and override the default of `.swc`. ##### Perf: simplify refresh wrapper generation ([#​835](https://redirect.github.com/vitejs/vite-plugin-react/pull/835)) ### [`v4.0.1`](https://redirect.github.com/vitejs/vite-plugin-react/blob/HEAD/packages/plugin-react-swc/CHANGELOG.md#401-2025-08-19) [Compare Source](https://redirect.github.com/vitejs/vite-plugin-react/compare/590f394c1e451987258ed64a4b5fb6207c5e8261...f21864b102d40fca4f70dfe9112a10101ec12f54) ##### Set `optimizeDeps.rollupOptions.transform.jsx` instead of `optimizeDeps.rollupOptions.jsx` for rolldown-vite ([#​735](https://redirect.github.com/vitejs/vite-plugin-react/pull/735)) `optimizeDeps.rollupOptions.jsx` is going to be deprecated in favor of `optimizeDeps.rollupOptions.transform.jsx`. ### [`v4.0.0`](https://redirect.github.com/vitejs/vite-plugin-react/blob/HEAD/packages/plugin-react-swc/CHANGELOG.md#400-2025-08-07) [Compare Source](https://redirect.github.com/vitejs/vite-plugin-react/compare/9e0c1038959e828865be810a164a51c3db1ac375...590f394c1e451987258ed64a4b5fb6207c5e8261) ### [`v3.11.0`](https://redirect.github.com/vitejs/vite-plugin-react/blob/HEAD/packages/plugin-react-swc/CHANGELOG.md#3110-2025-07-18) [Compare Source](https://redirect.github.com/vitejs/vite-plugin-react/compare/32d49ecf9b15e3070c7abe5a176252a3fe542e5c...9e0c1038959e828865be810a164a51c3db1ac375) ##### Add HMR support for compound components ([#​518](https://redirect.github.com/vitejs/vite-plugin-react/pull/518)) HMR now works for compound components like this: ```tsx const Root = () => <div>Accordion Root</div> const Item = () => <div>Accordion Item</div> export const Accordion = { Root, Item } ``` ##### Return `Plugin[]` instead of `PluginOption[]` ([#​537](https://redirect.github.com/vitejs/vite-plugin-react/pull/537)) The return type has changed from `react(): PluginOption[]` to more specialized type `react(): Plugin[]`. This allows for type-safe manipulation of plugins, for example: ```tsx // previously this causes type errors react() .map(p => ({ ...p, applyToEnvironment: e => e.name === 'client' })) ``` ### [`v3.10.2`](https://redirect.github.com/vitejs/vite-plugin-react/blob/HEAD/packages/plugin-react-swc/CHANGELOG.md#3102-2025-06-10) [Compare Source](https://redirect.github.com/vitejs/vite-plugin-react/compare/8ce7183265c43f88623655a9cfdcec5282068f9b...32d49ecf9b15e3070c7abe5a176252a3fe542e5c) ##### Suggest `@vitejs/plugin-react-oxc` if rolldown-vite is detected [#​491](https://redirect.github.com/vitejs/vite-plugin-react/pull/491) Emit a log which recommends `@vitejs/plugin-react-oxc` when `rolldown-vite` is detected to improve performance and use Oxc under the hood. The warning can be disabled by setting `disableOxcRecommendation: true` in the plugin options. ##### Use `optimizeDeps.rollupOptions` instead of `optimizeDeps.esbuildOptions` for rolldown-vite [#​489](https://redirect.github.com/vitejs/vite-plugin-react/pull/489) This suppresses the warning about `optimizeDeps.esbuildOptions` being deprecated in rolldown-vite. ##### Add Vite 7-beta to peerDependencies range [#​497](https://redirect.github.com/vitejs/vite-plugin-react/pull/497) React plugins are compatible with Vite 7, this removes the warning when testing the beta. ### [`v3.10.1`](https://redirect.github.com/vitejs/vite-plugin-react/blob/HEAD/packages/plugin-react-swc/CHANGELOG.md#3101-2025-06-03) [Compare Source](https://redirect.github.com/vitejs/vite-plugin-react/compare/dcadcfc2841c0bedfe44279c556835c350dfa5fa...8ce7183265c43f88623655a9cfdcec5282068f9b) ##### Add explicit semicolon in preambleCode [#​485](https://redirect.github.com/vitejs/vite-plugin-react/pull/485) This fixes an edge case when using HTML minifiers that strips line breaks aggressively. ### [`v3.10.0`](https://redirect.github.com/vitejs/vite-plugin-react/blob/HEAD/packages/plugin-react-swc/CHANGELOG.md#3100-2025-05-23) [Compare Source](https://redirect.github.com/vitejs/vite-plugin-react/compare/4a944487aabe4db16660f4196e1d6eed79edf0e0...dcadcfc2841c0bedfe44279c556835c350dfa5fa) ##### Add `filter` for rolldown-vite [#​470](https://redirect.github.com/vitejs/vite-plugin-react/pull/470) Added `filter` so that it is more performant when running this plugin with rolldown-powered version of Vite. ##### Skip HMR preamble in Vitest browser mode [#​478](https://redirect.github.com/vitejs/vite-plugin-react/pull/478) This was causing annoying `Sourcemap for "/@​react-refresh" points to missing source files` and is unnecessary in test mode. ##### Skip HMR for JSX files with hooks [#​480](https://redirect.github.com/vitejs/vite-plugin-react/pull/480) This removes the HMR warning for hooks with JSX. </details> --- ### 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. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0Mi45NS4yIiwidXBkYXRlZEluVmVyIjoiNDIuOTUuMiIsInRhcmdldEJyYW5jaCI6ImNhbmFyeSIsImxhYmVscyI6WyJkZXBlbmRlbmNpZXMiXX0=--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
This commit is contained in:
@@ -54,7 +54,7 @@
|
||||
"@toeverything/infra": "workspace:*",
|
||||
"@types/set-cookie-parser": "^2.4.10",
|
||||
"@types/uuid": "^11.0.0",
|
||||
"@vitejs/plugin-react-swc": "^3.7.2",
|
||||
"@vitejs/plugin-react-swc": "^4.0.0",
|
||||
"app-builder-lib": "^26.1.0",
|
||||
"builder-util-runtime": "^9.5.0",
|
||||
"cross-env": "^10.1.0",
|
||||
|
||||
@@ -593,7 +593,7 @@ __metadata:
|
||||
"@toeverything/infra": "workspace:*"
|
||||
"@types/set-cookie-parser": "npm:^2.4.10"
|
||||
"@types/uuid": "npm:^11.0.0"
|
||||
"@vitejs/plugin-react-swc": "npm:^3.7.2"
|
||||
"@vitejs/plugin-react-swc": "npm:^4.0.0"
|
||||
app-builder-lib: "npm:^26.1.0"
|
||||
async-call-rpc: "npm:^6.4.2"
|
||||
builder-util-runtime: "npm:^9.5.0"
|
||||
@@ -14886,6 +14886,13 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@rolldown/pluginutils@npm:1.0.0-rc.2":
|
||||
version: 1.0.0-rc.2
|
||||
resolution: "@rolldown/pluginutils@npm:1.0.0-rc.2"
|
||||
checksum: 10/8dba3626ca26f49ed83d4db4a9eaacfcc6715cc8544f2969419489c90a2bb000025976049e0f6c5c2880817bff753fb04bec8fb57df9423f07958ce8da97035e
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@rollup/pluginutils@npm:^5.0.2, @rollup/pluginutils@npm:^5.1.3, @rollup/pluginutils@npm:^5.3.0":
|
||||
version: 5.3.0
|
||||
resolution: "@rollup/pluginutils@npm:5.3.0"
|
||||
@@ -15817,92 +15824,92 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/core-darwin-arm64@npm:1.11.29":
|
||||
version: 1.11.29
|
||||
resolution: "@swc/core-darwin-arm64@npm:1.11.29"
|
||||
"@swc/core-darwin-arm64@npm:1.15.11":
|
||||
version: 1.15.11
|
||||
resolution: "@swc/core-darwin-arm64@npm:1.15.11"
|
||||
conditions: os=darwin & cpu=arm64
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/core-darwin-x64@npm:1.11.29":
|
||||
version: 1.11.29
|
||||
resolution: "@swc/core-darwin-x64@npm:1.11.29"
|
||||
"@swc/core-darwin-x64@npm:1.15.11":
|
||||
version: 1.15.11
|
||||
resolution: "@swc/core-darwin-x64@npm:1.15.11"
|
||||
conditions: os=darwin & cpu=x64
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/core-linux-arm-gnueabihf@npm:1.11.29":
|
||||
version: 1.11.29
|
||||
resolution: "@swc/core-linux-arm-gnueabihf@npm:1.11.29"
|
||||
"@swc/core-linux-arm-gnueabihf@npm:1.15.11":
|
||||
version: 1.15.11
|
||||
resolution: "@swc/core-linux-arm-gnueabihf@npm:1.15.11"
|
||||
conditions: os=linux & cpu=arm
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/core-linux-arm64-gnu@npm:1.11.29":
|
||||
version: 1.11.29
|
||||
resolution: "@swc/core-linux-arm64-gnu@npm:1.11.29"
|
||||
"@swc/core-linux-arm64-gnu@npm:1.15.11":
|
||||
version: 1.15.11
|
||||
resolution: "@swc/core-linux-arm64-gnu@npm:1.15.11"
|
||||
conditions: os=linux & cpu=arm64 & libc=glibc
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/core-linux-arm64-musl@npm:1.11.29":
|
||||
version: 1.11.29
|
||||
resolution: "@swc/core-linux-arm64-musl@npm:1.11.29"
|
||||
"@swc/core-linux-arm64-musl@npm:1.15.11":
|
||||
version: 1.15.11
|
||||
resolution: "@swc/core-linux-arm64-musl@npm:1.15.11"
|
||||
conditions: os=linux & cpu=arm64 & libc=musl
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/core-linux-x64-gnu@npm:1.11.29":
|
||||
version: 1.11.29
|
||||
resolution: "@swc/core-linux-x64-gnu@npm:1.11.29"
|
||||
"@swc/core-linux-x64-gnu@npm:1.15.11":
|
||||
version: 1.15.11
|
||||
resolution: "@swc/core-linux-x64-gnu@npm:1.15.11"
|
||||
conditions: os=linux & cpu=x64 & libc=glibc
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/core-linux-x64-musl@npm:1.11.29":
|
||||
version: 1.11.29
|
||||
resolution: "@swc/core-linux-x64-musl@npm:1.11.29"
|
||||
"@swc/core-linux-x64-musl@npm:1.15.11":
|
||||
version: 1.15.11
|
||||
resolution: "@swc/core-linux-x64-musl@npm:1.15.11"
|
||||
conditions: os=linux & cpu=x64 & libc=musl
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/core-win32-arm64-msvc@npm:1.11.29":
|
||||
version: 1.11.29
|
||||
resolution: "@swc/core-win32-arm64-msvc@npm:1.11.29"
|
||||
"@swc/core-win32-arm64-msvc@npm:1.15.11":
|
||||
version: 1.15.11
|
||||
resolution: "@swc/core-win32-arm64-msvc@npm:1.15.11"
|
||||
conditions: os=win32 & cpu=arm64
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/core-win32-ia32-msvc@npm:1.11.29":
|
||||
version: 1.11.29
|
||||
resolution: "@swc/core-win32-ia32-msvc@npm:1.11.29"
|
||||
"@swc/core-win32-ia32-msvc@npm:1.15.11":
|
||||
version: 1.15.11
|
||||
resolution: "@swc/core-win32-ia32-msvc@npm:1.15.11"
|
||||
conditions: os=win32 & cpu=ia32
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/core-win32-x64-msvc@npm:1.11.29":
|
||||
version: 1.11.29
|
||||
resolution: "@swc/core-win32-x64-msvc@npm:1.11.29"
|
||||
"@swc/core-win32-x64-msvc@npm:1.15.11":
|
||||
version: 1.15.11
|
||||
resolution: "@swc/core-win32-x64-msvc@npm:1.15.11"
|
||||
conditions: os=win32 & cpu=x64
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/core@npm:^1.10.1, @swc/core@npm:^1.11.21":
|
||||
version: 1.11.29
|
||||
resolution: "@swc/core@npm:1.11.29"
|
||||
"@swc/core@npm:^1.10.1, @swc/core@npm:^1.15.11":
|
||||
version: 1.15.11
|
||||
resolution: "@swc/core@npm:1.15.11"
|
||||
dependencies:
|
||||
"@swc/core-darwin-arm64": "npm:1.11.29"
|
||||
"@swc/core-darwin-x64": "npm:1.11.29"
|
||||
"@swc/core-linux-arm-gnueabihf": "npm:1.11.29"
|
||||
"@swc/core-linux-arm64-gnu": "npm:1.11.29"
|
||||
"@swc/core-linux-arm64-musl": "npm:1.11.29"
|
||||
"@swc/core-linux-x64-gnu": "npm:1.11.29"
|
||||
"@swc/core-linux-x64-musl": "npm:1.11.29"
|
||||
"@swc/core-win32-arm64-msvc": "npm:1.11.29"
|
||||
"@swc/core-win32-ia32-msvc": "npm:1.11.29"
|
||||
"@swc/core-win32-x64-msvc": "npm:1.11.29"
|
||||
"@swc/core-darwin-arm64": "npm:1.15.11"
|
||||
"@swc/core-darwin-x64": "npm:1.15.11"
|
||||
"@swc/core-linux-arm-gnueabihf": "npm:1.15.11"
|
||||
"@swc/core-linux-arm64-gnu": "npm:1.15.11"
|
||||
"@swc/core-linux-arm64-musl": "npm:1.15.11"
|
||||
"@swc/core-linux-x64-gnu": "npm:1.15.11"
|
||||
"@swc/core-linux-x64-musl": "npm:1.15.11"
|
||||
"@swc/core-win32-arm64-msvc": "npm:1.15.11"
|
||||
"@swc/core-win32-ia32-msvc": "npm:1.15.11"
|
||||
"@swc/core-win32-x64-msvc": "npm:1.15.11"
|
||||
"@swc/counter": "npm:^0.1.3"
|
||||
"@swc/types": "npm:^0.1.21"
|
||||
"@swc/types": "npm:^0.1.25"
|
||||
peerDependencies:
|
||||
"@swc/helpers": ">=0.5.17"
|
||||
dependenciesMeta:
|
||||
@@ -15929,7 +15936,7 @@ __metadata:
|
||||
peerDependenciesMeta:
|
||||
"@swc/helpers":
|
||||
optional: true
|
||||
checksum: 10/6945229bf6da91adff26033910e8e02ccc457a8229724d0539a0b32995d05949c7709cb9cae2cd7ab10cf4d346b235e22dd4d6b207ded765597304e21e6b6101
|
||||
checksum: 10/2ee702f6ee39fc68f1e4d03a19191eaa3762d54ab917d5617741196bbe3beba9fb50b1e878af2735f8a42ecdef3632f44acc090611ebf01a0df4dc533a71f5d2
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@@ -15958,12 +15965,12 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@swc/types@npm:^0.1.21":
|
||||
version: 0.1.21
|
||||
resolution: "@swc/types@npm:0.1.21"
|
||||
"@swc/types@npm:^0.1.25":
|
||||
version: 0.1.25
|
||||
resolution: "@swc/types@npm:0.1.25"
|
||||
dependencies:
|
||||
"@swc/counter": "npm:^0.1.3"
|
||||
checksum: 10/6554bf5c78519f49099a2ba448d170191a14b1c7a35df848f10ee4d6c03ecd681e5213884905187de1d1d221589ec8b5cb77f477d099dc1627c3ec9d7f2fcdb0
|
||||
checksum: 10/f6741450224892d12df43e5ca7f3cc0287df644dcd672626eb0cc2a3a8e3e875f4b29eb11336f37c7240cf6e010ba59eb3a79f4fb8bee5cbd168dfc1326ff369
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@@ -18163,14 +18170,15 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@vitejs/plugin-react-swc@npm:^3.7.2":
|
||||
version: 3.9.0
|
||||
resolution: "@vitejs/plugin-react-swc@npm:3.9.0"
|
||||
"@vitejs/plugin-react-swc@npm:^4.0.0":
|
||||
version: 4.2.3
|
||||
resolution: "@vitejs/plugin-react-swc@npm:4.2.3"
|
||||
dependencies:
|
||||
"@swc/core": "npm:^1.11.21"
|
||||
"@rolldown/pluginutils": "npm:1.0.0-rc.2"
|
||||
"@swc/core": "npm:^1.15.11"
|
||||
peerDependencies:
|
||||
vite: ^4 || ^5 || ^6
|
||||
checksum: 10/545dddee3c2f7f35f37c680f79bebb98f3968209470ec56c594556410d498b41cf86df60d2ab9a56c69b02bef12ee3198371becc804b85172ec97ee0d2d7633d
|
||||
vite: ^4 || ^5 || ^6 || ^7
|
||||
checksum: 10/48ab3de0a3833987ff7fc15d4561d930853acf1a2e44523279bc877f8ee81a368465f4b32f21155986986538514cc6aad3dfef62eb25490acde3593c970da521
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
|
||||
Reference in New Issue
Block a user