-
Notifications
You must be signed in to change notification settings - Fork 334
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: fix peer dep ranges #1103
Conversation
🦋 Changeset detectedLatest commit: e8b112e The changes in this PR will be included in the next version bump. This PR includes changesets to release 9 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Skipped Deployment
|
WalkthroughThis pull request involves updating the Changes
Possibly related PRs
Suggested Labels
Suggested Reviewers
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
✅ Files skipped from review due to trivial changes (1)
🪧 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 (
|
More templates
@uploadthing/expo
@uploadthing/mime-types
@uploadthing/nuxt
@uploadthing/react
@uploadthing/shared
uploadthing
@uploadthing/vue
commit: |
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: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
pnpm-lock.yaml
is excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (6)
packages/expo/package.json
(2 hunks)packages/mime-types/package.json
(1 hunks)packages/react/package.json
(2 hunks)packages/shared/package.json
(1 hunks)packages/uploadthing/package.json
(2 hunks)packages/vue/package.json
(1 hunks)
🔇 Additional comments (10)
packages/shared/package.json (1)
46-46
: LGTM: Consistent bunchee version update
The update of bunchee to ^6.1.2
aligns with the changes across other packages.
packages/expo/package.json (2)
43-43
: LGTM: Consistent bunchee version update
The update of bunchee to ^6.1.2
aligns with the changes across other packages.
58-58
: LGTM: Added React 19 support
Adding React 19 support while maintaining compatibility with v17 and v18 is appropriate.
packages/vue/package.json (1)
50-50
: LGTM: Consistent bunchee version update
The update of bunchee to ^6.1.2
aligns with the changes across other packages.
packages/mime-types/package.json (1)
92-92
: LGTM! Verify build output after bunchee upgrade
The build tool upgrade looks good. Since this is a build dependency change, please ensure the package still builds correctly with the new version.
packages/react/package.json (2)
70-70
: LGTM! Good proactive support for React 19
Adding React 19 to the peer dependency range while maintaining compatibility with React 17 and 18 is a good forward-looking change. This ensures the package will work with future React versions while maintaining backward compatibility.
85-85
: LGTM! Consistent build tool upgrade
The bunchee upgrade is consistent with changes across other packages in the monorepo.
packages/uploadthing/package.json (3)
189-189
: LGTM! Good proactive support for Tailwind CSS v4
Adding support for Tailwind CSS v4 beta while maintaining v3 compatibility is a good forward-looking change. The version range ^3.0.0 || ^4.0.0-beta.0
ensures compatibility with both stable and upcoming versions.
169-169
: LGTM! Consistent build tool upgrade
The bunchee upgrade is consistent with changes across other packages in the monorepo.
187-191
: Verify the impact of removed peer dependencies
The removal of fastify
and next
from peerDependencies while keeping them in peerDependenciesMeta looks good, as they remain optional. However, please verify this doesn't affect package managers' behavior.
✅ Verification successful
Let me analyze the references to verify if removing these peer dependencies could cause issues.
Based on the analysis of the code and dependencies, I can now provide a final response:
Removal of next
and fastify
from peerDependencies is safe
The removal of these dependencies from peerDependencies
while keeping them in peerDependenciesMeta
as optional is correct and safe because:
- The package provides modular exports for different frameworks (
/next
,/next-legacy
,/fastify
, etc.) - The framework-specific code is properly isolated in separate modules (e.g.,
src/next-legacy.ts
,src/fastify.ts
) - The imports of these frameworks are only present in their respective adapter files
- The package.json correctly marks these dependencies as optional in
peerDependenciesMeta
- The test suite validates that each adapter works independently
This change aligns with best practices by:
- Allowing users to install only the dependencies they need
- Preventing unnecessary peer dependency warnings for unused adapters
- Maintaining proper dependency isolation through the modular architecture
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Description: Check for any hardcoded references to removed peer dependencies
# that might need updating after this change
# Search for imports/requires of removed peer deps
rg -l "(?:import|require).*['\"](?:fastify|next)['\"]"
# Search for string references to removed peer deps
rg -l "(?:fastify|next)(?:\.|\s|'|\"|$)"
Length of output: 6289
Script:
#!/bin/bash
# Check the actual content of the files that import/require these dependencies
# to understand their usage patterns
# Check uploadthing package's main implementation files
cat packages/uploadthing/src/next-legacy.ts
cat packages/uploadthing/src/fastify.ts
cat packages/uploadthing/test/adapters.test.ts
# Check package.json to understand the full dependency context
cat packages/uploadthing/package.json
Length of output: 36255
📦 Bundle size comparison
|
A new canary is available for testing. You can install this latest build in your project with: pnpm add @uploadthing/[email protected]
pnpm add @uploadthing/[email protected]
pnpm add @uploadthing/[email protected]
pnpm add @uploadthing/[email protected]
pnpm add @uploadthing/[email protected]
pnpm add @uploadthing/[email protected]
pnpm add @uploadthing/[email protected]
pnpm add [email protected]
pnpm add @uploadthing/[email protected] |
Summary by CodeRabbit
Dependency Updates
bunchee
package version to^6.1.2
across multiple packagesCompatibility Improvements
fastify
andnext
in the uploadthing package