feat(react-native): Add Expo as a guide under React Native#18476
feat(react-native): Add Expo as a guide under React Native#18476antonis wants to merge 6 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
3bb38ac to
5c0b4d3
Compare
Make Expo a first-class guide under the React Native platform, mirroring the Dart>Flutter and JavaScript platform grouping. The docs home page and platform selector now show a single "React Native" dropdown containing "React Native" (bare/CLI) and "Expo" as siblings, with the Expo brand icon. - Move docs/platforms/react-native/* into common/ so the platform and its guides share content (public URLs are unchanged) - Add config.yml with platformTitle to drive the dropdown grouping - Add guides/expo/index.mdx Expo getting-started landing page - Add the Expo platform icon: a local copy of the (as-yet unreleased) getsentry/platformicons svg/expo.svg, wired through PLATFORM_TO_ICON so the react-native.expo guide key resolves to it instead of the React icon Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
5c0b4d3 to
8ed1d6a
Compare
|
|
||
| <AgentSkillsCallout skill="sentry-react-native-sdk" platformName="Expo" /> | ||
|
|
||
| On this page, we get you up and running with Sentry's React Native SDK in an [Expo](https://expo.dev/) project. The same `@sentry/react-native` SDK powers both bare React Native and Expo apps — this guide covers the Expo-specific setup (config plugin, Metro, EAS) and integrations. |
There was a problem hiding this comment.
| On this page, we get you up and running with Sentry's React Native SDK in an [Expo](https://expo.dev/) project. The same `@sentry/react-native` SDK powers both bare React Native and Expo apps — this guide covers the Expo-specific setup (config plugin, Metro, EAS) and integrations. | |
| Use this guide to get fully set up with Sentry's React Native SDK in an [Expo](https://expo.dev/) project. The same `@sentry/react-native` SDK powers both bare React Native and Expo apps. This guide covers the Expo-specific setup (config plugin, Metro, EAS) and integrations. |
There was a problem hiding this comment.
Applied with f9686c4
ps. Sorry for not applying your suggestion directly but it wasn't possible after merging from master
| ## Prerequisites | ||
|
|
||
| - [Expo SDK 50](https://docs.expo.dev/workflow/upgrading-expo-sdk-walkthrough/) or newer. | ||
| - [Expo SDK 49](https://docs.expo.dev/guides/using-sentry/) and older are supported by the `sentry-expo` package. |
There was a problem hiding this comment.
Do we have more information about the sentry-expo package? This feels like a dead end otherwise.
There was a problem hiding this comment.
And are we also saying that you can't use the native Expo SDK unless you migrate from it/update to Expo SDK 50? It sounds like that, but want to double check.
|
|
||
| ## Automatic Install | ||
|
|
||
| Use the [Sentry Wizard](https://github.com/getsentry/sentry-wizard) to patch your project automatically, as shown below. Alternatively, you can follow the [Manual Install](#manual-install) if you prefer. You only need to patch the project once. Then, you can add the patched files to your version control system. |
There was a problem hiding this comment.
Do we need to link to the wizard repo? I feel like it might be confusing - like go to the repo to install? Versus, here's the command in terminal (which is right below). But you tell me if this addition is valuable.
| Use the [Sentry Wizard](https://github.com/getsentry/sentry-wizard) to patch your project automatically, as shown below. Alternatively, you can follow the [Manual Install](#manual-install) if you prefer. You only need to patch the project once. Then, you can add the patched files to your version control system. | |
| Use the Sentry Wizard to patch your project automatically, as shown below. Alternatively, you can follow the [Manual Install](#manual-install) if you prefer. You only need to patch the project once. Then, you can add the patched files to your version control system. |
| To ensure bundles and source maps are automatically uploaded during the native applications builds, add `withSentry` to the Expo application configuration: | ||
|
|
||
| <Include name="react-native-expo-plugin-code-snippet.mdx" /> |
There was a problem hiding this comment.
Something is weird with the side nav focus for Expo specifically. When I click a link from the quick start (/platforms/react-native/guides/expo/) to links (maybe exclusively in the manual setup directory?), the left nav doesn't respond/loses focus. It also looks like the SDK menu bounces back to react native vs staying on expo. This screenshot is on /platforms/react-native/manual-setup/expo/expo-updates/, but the left nav isn't showing that. I think main culprit is that for some reason the left nav is bouncing to react native vs staying on expo.
Address PR review feedback on the Expo guide and incorporate the Slack discussion: - Reword the intro per review suggestion - Clarify the sentry-expo prerequisite (deprecated; requires Expo SDK 50+) and link it to the migration guide instead of a dead end - Drop the Sentry Wizard repo link (keep the command below it) - Reword the plugin step so it matches the snippet (plugins array in app.json, or withSentry in app.config.js/ts) - Point the guide's internal links at guide-scoped URLs so the sidebar stays on Expo when navigating (fixes the nav "bounce" to React Native) - Add an "Integrate Sentry with your EAS dashboard" section, porting the EAS deployment integration content, and cross-link it from /integrations/deployment/expo/ Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Expo-specific pages previously lived in the shared common/ tree, so they
also showed up in the bare React Native sidebar. Move them under the Expo
guide so they only appear there, and link them from the related React
Native pages instead.
- Move into guides/expo/: manual-setup/expo/{eas-build-hooks,expo-updates,
gradle}, migration/sentry-expo, sourcemaps/uploading/{expo,expo-advanced},
tracing/instrumentation/{expo-router,expo-resources}
- Delete the old manual-setup/expo.mdx setup page (superseded by the guide
landing) and redirect its URL to the guide
- Repoint links from bare-RN pages (index, sourcemaps, troubleshooting,
tracing) to the guide-scoped Expo URLs
- Add redirects from the old platform URLs to the new guide URLs
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…cker The common/ restructure brought every React Native page into the PR's link-check scope, surfacing three long-standing dead links: - Metro bundling docs moved to metrobundler.dev - facebook/metro and facebook/react-native repos moved to the react org Update them to their current canonical URLs (all verified 200). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|

DESCRIBE YOUR PR
Makes Expo a first-class guide under the React Native platform, mirroring how Dart>Flutter and the JavaScript platform are structured.
Fixes getsentry/sentry-react-native#6270.
IS YOUR CHANGE URGENT?
PRE-MERGE CHECKLIST
EXTRA RESOURCES