-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Logs(React-Native) Add getting started snippet #14790
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
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
| enableLogs: true, | ||
| // ___PRODUCT_OPTION_END___ logs |
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.
Potential bug: The React Native getting started guide uses an incorrect configuration, enableLogs: true. The SDK requires _experiments: { enableLogs: true }, causing logs to be silently dropped.
-
Description: The React Native getting started guide was updated to use
enableLogs: truein theSentry.init()call. However, the React Native SDK requires this option to be nested under an_experimentskey, as in_experiments: { enableLogs: true }. The top-levelenableLogsproperty is part of the JavaScript SDK v10, but this change was not adopted by the React Native SDK. Consequently, users following the updated guide will have logging silently disabled, as the configuration will be ignored without raising an error. -
Suggested fix: Update the
Sentry.init()example in the React Native getting started guide. Replace the top-levelenableLogs: trueproperty with_experiments: { enableLogs: true }to match the correct API for the React Native SDK.
severity: 0.72, confidence: 0.98
Did we get this right? 👍 / 👎 to inform future reviews.
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.
not a bad suggestion, it just isn't aware of an open PR changing this according to the updated implementation that will be merged at the same time as this
Bundle ReportChanges will increase total bundle size by 960 bytes (0.0%) ⬆️. This is within the configured threshold ✅ Detailed changes
Affected Assets, Files, and Routes:view changes for bundle: sentry-docs-server-cjsAssets Changed:
view changes for bundle: sentry-docs-client-array-pushAssets Changed:
|
antonis
left a comment
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.
LGTM 🚀
thank you for updating this 🙇
DESCRIBE YOUR PR
This change adds an interactive snippet on how to start Sentry React Native with Log support.
IS YOUR CHANGE URGENT?
Help us prioritize incoming PRs by letting us know when the change needs to go live.
SLA
Thanks in advance for your help!
PRE-MERGE CHECKLIST
Make sure you've checked the following before merging your changes:
EXTRA RESOURCES