From 8f391ae46e36f658510a9c30f880628b59606a5a Mon Sep 17 00:00:00 2001 From: Krystof Woldrich Date: Fri, 12 Jul 2024 12:28:22 +0200 Subject: [PATCH 1/4] misc(replay): Add Mobile Replay Public Beta changelog --- CHANGELOG.md | 47 +++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 43 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 62c3519394..2849c951e8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,8 +4,29 @@ ### Features -- Redact `react-native-svg` SVGs when `maskAllVectors` ([#3930](https://github.com/getsentry/sentry-react-native/pull/3930)) -- Add `annotateReactComponents` option to `@sentry/react-native/metro` ([#3916](https://github.com/getsentry/sentry-react-native/pull/3916)) +- Session Replay Public Beta ([#3830](https://github.com/getsentry/sentry-react-native/pull/3830)) + + To enable Replay use the `replaysSessionSampleRate` or `replaysOnErrorSampleRate` options. + + ```js + import * as Sentry from '@sentry/react-native'; + + Sentry.init({ + _experiments: { + replaysSessionSampleRate: 1.0, + replaysOnErrorSampleRate: 1.0, + }, + integrations: [ + Sentry.mobileReplayIntegration({ + maskAllImages: true, + maskAllVectors: true, + maskAllText: true, + }), + ], + }); + ``` + + To add React Component Names use `annotateReactComponents` in `metro.config.js`. ```js // For Expo @@ -18,9 +39,27 @@ module.exports = withSentryConfig(getDefaultConfig(__dirname), { annotateReactComponents: true }); ``` -### Fixes + To change default redaction behavior add the `mobileReplayIntegration`. + + ```js + import * as Sentry from '@sentry/react-native'; + + Sentry.init({ + _experiments: { + replaysSessionSampleRate: 1.0, + replaysOnErrorSampleRate: 1.0, + }, + integrations: [ + Sentry.mobileReplayIntegration({ + maskAllImages: true, + maskAllVectors: true, + maskAllText: true, + }), + ], + }); + ``` -- Add `app.foreground/background` breadcrumbs to iOS Replays ([#3932](https://github.com/getsentry/sentry-react-native/pull/3932)) + To learn more visit [Sentry's Mobile Session Replay](https://docs.sentry.io/product/explore/session-replay/) documentation page. ### Dependencies From 7d8a70860b5057bec4ce0285b56b61b900608c48 Mon Sep 17 00:00:00 2001 From: Krystof Woldrich Date: Fri, 12 Jul 2024 15:32:20 +0200 Subject: [PATCH 2/4] fix public changelog after latest alpha --- CHANGELOG.md | 33 ++++++++++++++++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4e60cd4f15..745b81a146 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # Changelog -## 5.26.0-alpha.3 +## Unreleased ### Features @@ -63,6 +63,37 @@ ### Dependencies +- Bump Android SDK from v7.11.0-alpha.2 to v7.12.0-alpha.4 ([#3830](https://github.com/getsentry/sentry-react-native/pull/3830)) + - [changelog](https://github.com/getsentry/sentry-java/blob/7.12.0-alpha.3/CHANGELOG.md#7120-alpha4) + - [diff](https://github.com/getsentry/sentry-java/compare/7.11.0-alpha.2...7.12.0-alpha.4) +- Bump Cocoa SDK from v8.30.0 to v8.30.1 ([#3936](https://github.com/getsentry/sentry-react-native/pull/3936)) + - [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8301) + - [diff](https://github.com/getsentry/sentry-cocoa/compare/8.30.0...8.30.1) + +## 5.26.0-alpha.3 + +### Features + +- Redact `react-native-svg` SVGs when `maskAllVectors` ([#3930](https://github.com/getsentry/sentry-react-native/pull/3930)) +- Add `annotateReactComponents` option to `@sentry/react-native/metro` ([#3916](https://github.com/getsentry/sentry-react-native/pull/3916)) + + ```js + // For Expo + const { getSentryExpoConfig } = require("@sentry/react-native/metro"); + const config = getSentryExpoConfig(__dirname, { annotateReactComponents: true }); + + // For RN + const { getDefaultConfig } = require('@react-native/metro-config'); + const { withSentryConfig } = require('@sentry/react-native/metro'); + module.exports = withSentryConfig(getDefaultConfig(__dirname), { annotateReactComponents: true }); + ``` + +### Fixes + +- Add `app.foreground/background` breadcrumbs to iOS Replays ([#3932](https://github.com/getsentry/sentry-react-native/pull/3932)) + +### Dependencies + - Bump Android SDK from v7.11.0-alpha.2 to v7.12.0-alpha.4 ([#3830](https://github.com/getsentry/sentry-react-native/pull/3830)) - [changelog](https://github.com/getsentry/sentry-java/blob/7.12.0-alpha.3/CHANGELOG.md#7120-alpha4) - [diff](https://github.com/getsentry/sentry-java/compare/7.11.0-alpha.2...7.12.0-alpha.4) From d2ef3b5df4062632b4b144798349e32984f4c0eb Mon Sep 17 00:00:00 2001 From: Krystof Woldrich <31292499+krystofwoldrich@users.noreply.github.com> Date: Fri, 12 Jul 2024 19:14:40 +0200 Subject: [PATCH 3/4] Update CHANGELOG.md --- CHANGELOG.md | 7 ------- 1 file changed, 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 745b81a146..5d93c03d34 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,13 +16,6 @@ replaysSessionSampleRate: 1.0, replaysOnErrorSampleRate: 1.0, }, - integrations: [ - Sentry.mobileReplayIntegration({ - maskAllImages: true, - maskAllVectors: true, - maskAllText: true, - }), - ], }); ``` From 057778e294d65ee740852379178ff5e0e87ea28e Mon Sep 17 00:00:00 2001 From: Roman Zavarnitsyn Date: Mon, 15 Jul 2024 19:43:59 +0200 Subject: [PATCH 4/4] Update CHANGELOG.md --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5d93c03d34..53509dcc52 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -52,7 +52,7 @@ }); ``` - To learn more visit [Sentry's Mobile Session Replay](https://docs.sentry.io/product/explore/session-replay/) documentation page. + To learn more visit [Sentry's Mobile Session Replay](https://docs.sentry.io/product/explore/session-replay/mobile/) documentation page. ### Dependencies