You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
chore(examples/react): add '@types/react' to the examples that relied on the root one - #11960
Eleven React examples don't declare @types/react. They used to resolve the root's copy, which #11727 removed, so type-checking them now fails on every JSX element and React import (for example, offline went from its own few errors to 62).
Add @types/react to basic-graphql-request, chat, default-query-function, devtools-panel, offline, playground, react-native, rick-morty, simple, star-wars and suspense, and @types/react-dom to the ones that use react-dom. The versions match the other React examples.
basic-graphql-request, chat, default-query-function and devtools-panel now type-check without errors. The remaining errors in the other examples are in the examples' own code and will be fixed separately.
I have tested code changes locally with pnpm run test:pr, or these tests do not apply to this pull request.
I have followed the AI contribution policy and fully understand the code in this pull request, including any code generated with AI assistance.
🚀 Release Impact
This change affects published code, and I have generated a changeset.
This change is docs/CI/dev-only (no release).
Summary by CodeRabbit
Chores
Updated the React examples’ development setup with React type definitions, improving TypeScript support across the examples. This includes the React Native example, which received React type definitions; the other listed examples also received React DOM type definitions.
Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.
This PR includes no changesets
When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 8 remain after this review.
📝 Walkthrough
Walkthrough
Eleven React example package manifests now include React type packages as development dependencies. The React Native example adds @types/react; the other ten examples add @types/react and @types/react-dom.
The dependency changes appear mergeable after normal checks. The examples’ React types match their resolved React versions, and the lockfile is updated.
Pre-merge checks | 5
✅ Passed checks (5 passed)
Check name
Status
Explanation
Title check
The title clearly identifies the main change: adding React type dependencies to React examples. It is concise and directly related, although it does not mention the related @types/react-dom additions.
Description check
The description follows the required template, explains the motivation and scope, records testing, includes the AI policy checklist, and identifies the change as dev-only with no release impact.
Docstring Coverage
No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🎯 Changes
Eleven React examples don't declare
@types/react. They used to resolve the root's copy, which #11727 removed, so type-checking them now fails on every JSX element and React import (for example,offlinewent from its own few errors to 62).@types/reacttobasic-graphql-request,chat,default-query-function,devtools-panel,offline,playground,react-native,rick-morty,simple,star-warsandsuspense, and@types/react-domto the ones that usereact-dom. The versions match the other React examples.basic-graphql-request,chat,default-query-functionanddevtools-panelnow type-check without errors. The remaining errors in the other examples are in the examples' own code and will be fixed separately.✅ Checklist
pnpm run test:pr, or these tests do not apply to this pull request.🚀 Release Impact
Summary by CodeRabbit