Skip to content

Commit 230ed72

Browse files
yamcodesCopilotcursoragent
authored
fix: widen @arkenv/nextjs React peer range (#1833)
## Summary Fix the React peer dependency conflict affecting Next.js example installs. ## Root cause `@arkenv/nextjs` used the pnpm workspace-only `catalog:` alias for its published React peer dependency. The resulting npm metadata pinned React to `19.2.5`, conflicting with projects using React `19.2.8` and causing `ERESOLVE` during installs. ## Fix Set the peer dependency to the supported React range: ```json "react": "^18.2.0 || ^19.0.0" ``` This matches Next.js's supported React range and allows the examples to resolve successfully. --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Co-authored-by: Cursor Agent <cursoragent@cursor.com>
1 parent 25b2cca commit 230ed72

3 files changed

Lines changed: 9 additions & 1 deletion

File tree

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
"@arkenv/nextjs": patch
3+
---
4+
5+
#### Widen the React peer dependency range
6+
7+
Replace the workspace `catalog:` alias for the published React peer dependency with `"^18.2.0 || ^19.0.0"` so installs are not pinned to a single React version.

packages/nextjs/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
"peerDependencies": {
3333
"arktype": "^2.1.22",
3434
"next": "^13.4.0 || ^14.0.0 || ^15.0.0 || ^16.0.0-0",
35-
"react": "catalog:"
35+
"react": "^18.2.0 || ^19.0.0"
3636
},
3737
"exports": {
3838
"./shared": {

packages/nextjs/src/script.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ export function ArkEnvScript({
3939
return (
4040
<script
4141
id="arkenv-script"
42+
// biome-ignore lint/security/noDangerouslySetInnerHtml: JSON-serialized public env with `<` escaped
4243
dangerouslySetInnerHTML={{ __html: scriptContent }}
4344
/>
4445
);

0 commit comments

Comments
 (0)