build(deps-dev): bump @vitejs/plugin-react from 4.7.0 to 5.1.2#613
build(deps-dev): bump @vitejs/plugin-react from 4.7.0 to 5.1.2#613dependabot[bot] wants to merge 1 commit intomainfrom
Conversation
|
@dependabot rebase |
52f4985 to
bdad8ed
Compare
|
@dependabot rebase |
|
Looks like this PR is already up-to-date with main! If you'd still like to recreate it from scratch, overwriting any edits, you can request |
|
@dependabot recreate |
bdad8ed to
03cd5f2
Compare
|
@dependabot rebase |
Bumps [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/tree/HEAD/packages/plugin-react) from 4.7.0 to 5.1.2. - [Release notes](https://github.com/vitejs/vite-plugin-react/releases) - [Changelog](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/CHANGELOG.md) - [Commits](https://github.com/vitejs/vite-plugin-react/commits/[email protected]/packages/plugin-react) --- updated-dependencies: - dependency-name: "@vitejs/plugin-react" dependency-version: 5.1.2 dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]>
03cd5f2 to
6d94839
Compare
Build Failure DetailsError Message: Failing Workflow: Root Cause Analysis1. Package Structure Change in v5.xThe v4.x package.json: {
"main": "./dist/index.cjs",
"types": "./dist/index.d.ts",
"exports": {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.mjs",
"require": "./dist/index.cjs"
}
}
}v5.x package.json: {
"type": "module",
"exports": {
".": "./dist/index.js",
"./preamble": "./types/preamble.d.ts"
}
// NO "main" field
// NO "types" field
}2. TypeScript Module Resolution MismatchThe project's {
"moduleResolution": "Node"
}This legacy resolution mode (also called "Node10"):
Since v5.x removed all fallback fields, TypeScript cannot find the type declarations. 3. Build Pipeline TriggerThe error occurs during the Rollup build because:
Solution OptionsOption A: Update moduleResolution (Recommended)Change {
"compilerOptions": {
"moduleResolution": "Bundler"
}
}Pros:
Cons:
Required Changes:
Option B: Separate Build tsconfigCreate a dedicated tsconfig for Rollup that excludes New file: {
"extends": "./tsconfig.json",
"include": ["src"],
"exclude": ["node_modules", "dist", "example", "vite.config.ts", "setupTest.ts", "cypress.config.ts", "cypress"]
}Update typescript({
tsconfig: './tsconfig.build.json',
noEmitOnError: true,
})Pros:
Cons:
Option C: Wait for Upstream FixThe missing {
"types": "./dist/index.d.ts"
}Action: Report issue to https://github.com/vitejs/vite-plugin-react Pros:
Cons:
Additional Breaking Changes in v5.xNode.js Engine Requirement// v4.x
"engines": { "node": "^14.18.0 || >=16.0.0" }
// v5.x
"engines": { "node": "^20.19.0 || >=22.12.0" }Status: ✅ Compatible (project uses Node.js 22.20.0) Dependency Changes
Files Affected
Testing ChecklistAfter implementing the fix:
Reproduction StepsTo reproduce the build failure locally: # Fetch the PR branch
git fetch origin dependabot/npm_and_yarn/vitejs/plugin-react-5.1.2
# Checkout the branch
git checkout origin/dependabot/npm_and_yarn/vitejs/plugin-react-5.1.2 --detach
# Clean install
rm -rf node_modules lib/node_modules app/node_modules
# Install from lib directory (simulates CI)
cd lib && npm install
# Attempt build (will fail)
npm run buildRecommendationImplement Option A (update
After implementing the fix, rebase this PR and verify all CI checks pass. |
|
Superseded by #699. |
Bumps @vitejs/plugin-react from 4.7.0 to 5.1.2.
Release notes
Sourced from
@vitejs/plugin-react's releases.... (truncated)
Changelog
Sourced from
@vitejs/plugin-react's changelog.... (truncated)
Commits
f127a24release: [email protected]db1c665fix(react): newer full bundle mode compat (#1011)1f372b6fix(deps): update all non-major dependencies (#1008)d52455efix(deps): update react 19.2.1 (#998)bcda041fix(deps): update all non-major dependencies (#995)c80546dfix(deps): update all non-major dependencies (#982)23db727release: [email protected]bcc7db0chore: add changelog for #976 and #9784a2e229fix(react): use rolldownOptions instead of deprecated rollupOptions in optimi...41cb823fix(deps): update all non-major dependencies (#968)Maintainer changes
This version was pushed to npm by [GitHub Actions](https://www.npmjs.com/~GitHub Actions), a new releaser for
@vitejs/plugin-reactsince your current version.You can trigger a rebase of this PR by commenting
@dependabot rebase.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
@dependabot rebasewill rebase this PR@dependabot recreatewill recreate this PR, overwriting any edits that have been made to it@dependabot mergewill merge this PR after your CI passes on it@dependabot squash and mergewill squash and merge this PR after your CI passes on it@dependabot cancel mergewill cancel a previously requested merge and block automerging@dependabot reopenwill reopen this PR if it is closed@dependabot closewill close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually@dependabot show <dependency name> ignore conditionswill show all of the ignore conditions of the specified dependency@dependabot ignore this major versionwill close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this minor versionwill close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this dependencywill close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)