-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: update-next #1758
chore: update-next #1758
Conversation
WalkthroughThe changes in this pull request involve updates to the Changes
Possibly related PRs
Suggested labels
Suggested reviewers
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
❌ Deploy Preview for kleros-v2-testnet failed. Why did it fail? →
|
❌ Deploy Preview for kleros-v2-testnet-devtools failed. Why did it fail? →
|
❌ Deploy Preview for kleros-v2-university failed. Why did it fail? →
|
Code Climate has analyzed commit 5916a7b and detected 0 issues on this pull request. View more on Code Climate. |
|
✅ Deploy Preview for kleros-v2-neo ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
🧹 Outside diff range and nitpick comments (1)
web-devtools/package.json (1)
54-54
: Consider using stricter version constraintsUsing
^
for a major framework version could lead to unexpected breaking changes. Consider:
- Using a fixed version (
15.0.3
) for more controlled updates- Or at minimum, using a tilde (
~15.0.3
) to only allow patch updates
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
⛔ Files ignored due to path filters (1)
yarn.lock
is excluded by!**/yarn.lock
,!**/*.lock
📒 Files selected for processing (2)
web-devtools/package.json
(1 hunks)web-devtools/tsconfig.json
(1 hunks)
🔇 Additional comments (2)
web-devtools/tsconfig.json (2)
Line range hint 1-41
: Verify TypeScript configuration for Next.js 15 compatibility
The TypeScript configuration appears compatible with Next.js 15, but let's verify there aren't any missing recommended settings.
✅ Verification successful
TypeScript configuration is compatible with Next.js 15
The TypeScript configuration in tsconfig.json
is properly set up for Next.js 15:
- Using correct
moduleResolution: "bundler"
for Next.js 15 - Has the required Next.js plugin configured
- Includes all necessary compiler options (
strict
,esModuleInterop
, etc.) - TypeScript 5.5.3 is being used, which is compatible with Next.js 15.0.3
The Next.js configuration in next.config.mjs
is also properly configured with TypeScript support and doesn't override any critical TypeScript settings.
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Description: Check for Next.js 15 TypeScript configuration recommendations
# Look for Next.js specific configuration files
rg -l 'next\.config\.(js|ts)' .
# Check if there are any TypeScript-related warnings in the Next.js configuration
rg -A 5 'typescript|compilerOptions' next.config.* 2>/dev/null
Length of output: 88
Script:
#!/bin/bash
# Let's try a different approach to verify Next.js and TypeScript configuration
# Check for Next.js version in package.json
rg -A 2 '"next":' package.json
# Look for any Next.js specific TypeScript configuration files
fd -e json -e js -e ts -x grep -l "next" {}
# Check for any TypeScript configuration files
fd tsconfig
# Check if there are any TypeScript errors or warnings in the build output
fd -e log build-error
Length of output: 4514
Script:
#!/bin/bash
# Let's check the package.json for Next.js version and TypeScript dependencies
cat web-devtools/package.json | jq '.dependencies.next, .dependencies.typescript, .devDependencies.typescript'
# Let's also check for any Next.js specific configuration
fd next.config -e js -e ts -e mjs web-devtools/
# And verify the content of any Next.js config file if found
fd next.config -e js -e ts -e mjs web-devtools/ -x cat {}
Length of output: 1540
40-41
: Consider using a more modern TypeScript target.
While ES2017 is a valid target and includes important features like async/await, you might want to consider using a more modern target (like ES2020 or ES2022) since:
- Next.js 15 supports modern JavaScript features
- Most modern browsers support ES2020+ features
- You're already using "esnext" for module and lib settings
Let's verify the browser requirements for your project:
✅ Verification successful
ES2017 target is appropriate for the project's browser compatibility requirements.
The browserslist configuration in web-devtools/package.json ("> 0.5%, not dead"
) indicates support for modern browsers, and ES2017 target is compatible with this requirement. The target setting aligns well with:
- The project's browser compatibility needs
- Next.js 15's requirements
- The browserslist configuration
- Usage of modern features in dependencies like viem, wagmi, etc.
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Description: Check browser targets configuration
# Look for browserslist config in package.json or .browserslistrc
rg -l 'browserslist|"targets"' package.json .browserslistrc
Length of output: 117
Script:
#!/bin/bash
# Let's check package.json for browser targets and other relevant configurations
fd -t f "package.json" -x cat {}
# Also check for any babel config that might define targets
fd -t f "^\.babelrc|babel\.config\.(js|json)$" -x cat {}
# Check for any Next.js config files that might define browser targets
fd -t f "^next\.config\.(js|ts|mjs)$" -x cat {}
Length of output: 28323
@@ -51,7 +51,7 @@ | |||
"@web3modal/wagmi": "^5.1.11", | |||
"graphql": "^16.9.0", | |||
"graphql-request": "^7.1.0", | |||
"next": "14.2.14", | |||
"next": "^15.0.3", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Version mismatch with eslint-config-next
The project is using eslint-config-next@^14.2.15
but upgrading to next@^15.0.3
. These versions should match to ensure proper linting rules.
Apply this change:
- "eslint-config-next": "^14.2.15",
+ "eslint-config-next": "^15.0.3",
Committable suggestion skipped: line range outside the PR's diff.
💡 Codebase verification
The project is using Next.js 15.0.3 but eslint-config-next is still on 14.2.15. This version mismatch could lead to linting issues. However, the project is already using the App Router pattern which is compatible with Next.js 15. Please:
- Update eslint-config-next to version 15:
"eslint-config-next": "^15.0.3"
- Keep the caret (^) version constraint for Next.js as it's appropriate for framework dependencies within the same major version.
🔗 Analysis chain
This is a major version upgrade from Next.js 14 to 15, which introduces breaking changes. Please ensure:
- Review of the Next.js 15 migration guide
- Testing of all application features
- CI pipeline passes with the new version
Let me gather more information about the Next.js configuration and dependencies to provide a more comprehensive verification.
Let me check the Next.js configuration and app structure to verify potential breaking changes.
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Check for Next.js specific patterns that might need updates in v15
echo "Checking for potential breaking changes..."
# Check for usage of deprecated features
rg -l "getInitialProps|getServerSideProps|getStaticProps|getStaticPaths"
# Check for custom server implementations
fd "server.js|server.ts"
# Check for custom webpack config
fd "next.config.js|next.config.ts"
Length of output: 233
Script:
#!/bin/bash
# Check package.json for Next.js related dependencies and configurations
cat web-devtools/package.json
# Look for any Next.js specific files and components
fd -e tsx -e jsx -e js -e ts
# Check for app directory structure (Next.js 13+ feature)
fd -t d "app"
# Look for pages directory (traditional Next.js structure)
fd -t d "pages"
Length of output: 26687
Script:
#!/bin/bash
# Check Next.js configuration
cat web-devtools/next.config.js 2>/dev/null || echo "No next.config.js found"
# Check for app directory usage
fd -t f . web-devtools/src/app/
# Check package.json for Next.js related dependencies
grep -A 5 -B 5 "next\":" web-devtools/package.json
Length of output: 1773
Issue found, v14 to v15 update for |
PR-Codex overview
This PR primarily updates the configuration and dependencies for a web development project, particularly upgrading the
next
version and making various adjustments to theyarn.lock
file, including adding new dependencies and updating existing ones.Detailed summary
target
intsconfig.json
toES2017
.next
from14.2.14
to^15.0.3
inpackage.json
.@img/sharp
for image processing inyarn.lock
.styled-jsx
from5.1.1
to5.1.6
.simple-swizzle
andcolor-string
dependencies with specific versions.react
versions.Summary by CodeRabbit
These changes enhance the project's ability to leverage the latest updates and maintain compatibility across environments.