Repository navigation
build(deps): bump view shot to better support new arch - #13864
Conversation
| "paths": { | ||
| // react-native-view-shot's `exports` map points the "react-native" condition at its raw | ||
| // `src/index.tsx`, so tsc type-checks the library source (skipLibCheck only covers `.d.ts`) | ||
| // and our noUnusedLocals flags its unused imports. Point tsc at the shipped declarations | ||
| // instead; Metro still bundles the react-native source. Remove once upstream is clean. | ||
| "react-native-view-shot": ["../node_modules/react-native-view-shot/lib/index.d.ts"] | ||
| }, |
There was a problem hiding this comment.
Good comment explaining the what, but "Remove once upstream is clean" has no way to be actioned. Add a link to the upstream issue (or open one) so the next person bumping this knows what to check.
Two notes on the approach:
- This makes
tscreadlib/index.d.tswhile Metro and Jest bundlesrc/index.tsx. Fine as long aslib/is emitted from that same source, but it's a divergence to be aware of if the library's build ever changes. - The repo already patches 12 packages (
.yarn/patches/), so ayarn patchremoving the unused imports from the library'ssrc/index.tsxis an alternative that keeps tsc and Metro on the same file. Trade-off is patch maintenance on every bump, so the tsconfig override is a reasonable call — just flagging the option.
Also worth confirming this paths block didn't disturb baseUrl: "src" resolution for app/… imports. TypeScript falls back to baseUrl when no paths pattern matches, so it should be fine, but yarn type-check passing is the proof.
SummaryBumps The code changes are minimal and correct for the new ref type. Comments below are about verification, not the diff. Issues Found🟡 ImportantAndroid is unverified for a native-module major bump. The checklist has Android unchecked, and both video cells in the description are still placeholder 🟢 SuggestionThe capture path has no test coverage. See the inline comment on Areas Reviewed
Questions for Author
|
This PR resolves []
Description
Bumps react-native-view-shot to latest for better new arch support
Nothing changed behavior wise
debug.mov
debugafter.mp4
shareAfter.mp4
PR Checklist
To the reviewers 👀
Changelog updates
Changelog updates
Cross-platform user-facing changes
iOS user-facing changes
Android user-facing changes
Dev changes
Need help with something? Have a look at our docs, or get in touch with us.