Unverified Commit 863168d4 authored by Mo Beigi's avatar Mo Beigi Committed by GitHub

Sync @next/third-parties with React peer versions (#71261)

parent b6fa6be4
...@@ -33,6 +33,6 @@ ...@@ -33,6 +33,6 @@
}, },
"peerDependencies": { "peerDependencies": {
"next": "^13.0.0 || ^14.0.0 || ^15.0.0", "next": "^13.0.0 || ^14.0.0 || ^15.0.0",
"react": "^18.2.0 || 19.0.0-rc-70fb1363-20241010" "react": "^18.2.0 || 19.0.0-rc-cd22717c-20241013"
} }
} }
...@@ -21,6 +21,7 @@ const filesReferencingReactPeerDependencyVersion = [ ...@@ -21,6 +21,7 @@ const filesReferencingReactPeerDependencyVersion = [
'test/lib/next-modes/base.ts', 'test/lib/next-modes/base.ts',
] ]
const appManifestsInstallingNextjsPeerDependencies = [ const appManifestsInstallingNextjsPeerDependencies = [
'packages/third-parties/package.json',
'examples/reproduction-template/package.json', 'examples/reproduction-template/package.json',
'test/.stats-app/package.json', 'test/.stats-app/package.json',
// TODO: These should use the usual test helpers that automatically install the right React version // TODO: These should use the usual test helpers that automatically install the right React version
...@@ -344,8 +345,12 @@ Or, run this command with no arguments to use the most recently published versio ...@@ -344,8 +345,12 @@ Or, run this command with no arguments to use the most recently published versio
const packageJsonPath = path.join(cwd, fileName) const packageJsonPath = path.join(cwd, fileName)
const packageJson = await fsp.readFile(packageJsonPath, 'utf-8') const packageJson = await fsp.readFile(packageJsonPath, 'utf-8')
const manifest = JSON.parse(packageJson) const manifest = JSON.parse(packageJson)
if (manifest.dependencies['react']) {
manifest.dependencies['react'] = newVersionStr manifest.dependencies['react'] = newVersionStr
}
if (manifest.dependencies['react-dom']) {
manifest.dependencies['react-dom'] = newVersionStr manifest.dependencies['react-dom'] = newVersionStr
}
await fsp.writeFile( await fsp.writeFile(
packageJsonPath, packageJsonPath,
JSON.stringify(manifest, null, 2) + JSON.stringify(manifest, null, 2) +
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment