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
Remove deprecated FeedbackButton from React Native docs (#17191)
**Based on #17190
## DESCRIBE YOUR PR
Remove all references to the deprecated `FeedbackButton`,
`showFeedbackButton`, and `hideFeedbackButton` APIs from the React
Native user feedback documentation.
Removed:
- `showFeedbackButton`/`hideFeedbackButton` code examples and mentions
from the main user feedback page
- Entire "Feedback Button Customization" section from the configuration
page
- `FeedbackButton` reference in the image picker section
Follows SDK deprecation in getsentry/sentry-react-native#5933.
## IS YOUR CHANGE URGENT?
- [ ] Urgent deadline (GA date, etc.):
- [ ] Other deadline:
- [x] None: Not urgent, can wait up to 1 week+
⚠️ Should be merged after
getsentry/sentry-react-native#5933 is released
## PRE-MERGE CHECKLIST
- [ ] Checked Vercel preview for correctness, including links
- [ ] PR was reviewed and approved by any necessary SMEs (subject matter
experts)
- [ ] PR was reviewed and approved by a member of the [Sentry docs
team](https://github.com/orgs/getsentry/teams/docs)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The User Feedback Form offers many customization options, and if the available options are insufficient, you can [use your own UI](/platforms/react-native/user-feedback/#user-feedback-api).
9
9
10
10

11
-
To collect user feedback from inside your application, use the `showFeedbackButton`/`hideFeedbackButton` to show/hide a button that triggers the Feedback Form or the `showFeedbackForm` method to present the form directly.
11
+
To collect user feedback from inside your application, use the `showFeedbackForm` method to present the form.
12
12
13
-
```JavaScript {tabTitle:Form}
13
+
```JavaScript
14
14
import*asSentryfrom"@sentry/react-native";
15
15
16
16
Sentry.wrap(RootComponent);
17
17
18
18
Sentry.showFeedbackForm();
19
19
```
20
20
21
-
```JavaScript {tabTitle:Button}
22
-
import*asSentryfrom"@sentry/react-native";
23
-
24
-
Sentry.wrap(RootComponent);
25
-
26
-
Sentry.showFeedbackButton();
27
-
Sentry.hideFeedbackButton();
28
-
```
29
-
30
21
Note that [the root application component must be wrapped with `Sentry.wrap`](/platforms/react-native/#wrap-your-app) for this to work.
31
22
32
23
## General
@@ -140,47 +131,6 @@ The following styles are available for customisation.
140
131
|`screenshotThumbnail`|`ImageStyle`| The screenshot thumbnail image style. |
141
132
|`titleContainer`|`ViewStyle`| The title container style. |
142
133
143
-
## Feedback Button Customization
144
-
145
-
You can customize placement of the feedback button, as well as the fonts and colors.
146
-
147
-
The example below shows how to customize the bottom margin with the `feedbackIntegration`.
148
-
149
-
```javascript
150
-
import*asSentryfrom"@sentry/react-native";
151
-
152
-
Sentry.init({
153
-
integrations: [
154
-
Sentry.feedbackIntegration({
155
-
buttonOptions: {
156
-
styles: {
157
-
triggerButton: {
158
-
marginBottom:75,
159
-
},
160
-
},
161
-
},
162
-
}),
163
-
],
164
-
});
165
-
166
-
Sentry.showFeedbackButton();
167
-
```
168
-
169
-
You can customize the button text with the following options.
|`triggerButton`|`ViewStyle`| The feedback button style. |
181
-
|`triggerText`|`TextStyle`| The feedback button text style. |
182
-
|`triggerIcon`|`ImageStyle`| The feedback button icon style. |
183
-
184
134
## Event Callbacks
185
135
186
136
The following callbacks can be configured for the integration in `feedbackIntegration({})` or passed in the `FeedbackForm` component props:
@@ -228,7 +178,7 @@ Sentry.init({
228
178
});
229
179
```
230
180
231
-
The `imagePicker` integration is used when launching the feedback form with the `showFeedbackForm` or the `FeedbackButton`. In order to use it with a custom `FeedbackForm` component, you need to pass the `imagePicker` prop to the component as shown below:
181
+
The `imagePicker` integration is used when launching the feedback form with `showFeedbackForm`. In order to use it with a custom `FeedbackForm` component, you need to pass the `imagePicker` prop to the component as shown below:
232
182
233
183
```javascript
234
184
<FeedbackForm
@@ -270,6 +220,7 @@ import * as Sentry from "@sentry/react-native";
270
220
Sentry.init({
271
221
integrations: [
272
222
Sentry.feedbackIntegration({
223
+
enableTakeScreenshot:true,
273
224
screenshotButtonOptions: {
274
225
triggerLabel:'Take Screenshot',
275
226
styles: {
@@ -281,8 +232,6 @@ Sentry.init({
281
232
}),
282
233
],
283
234
});
284
-
285
-
Sentry.showFeedbackButton();
286
235
```
287
236
288
237
You can customize the Feedback Form screenshot button text with the following options.
Copy file name to clipboardExpand all lines: docs/platforms/react-native/user-feedback/index.mdx
+3-14Lines changed: 3 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -29,20 +29,9 @@ Sentry.wrap(RootComponent);
29
29
Sentry.showFeedbackForm();
30
30
```
31
31
32
-
You may also use the `showFeedbackButton` and `hideFeedbackButton`to show and hide a button that opens the Feedback Form.
32
+
Note that [the root application component must be wrapped with `Sentry.wrap`](/platforms/react-native/#wrap-your-app) for the `showFeedbackForm` method to work. The method depends on the React Native `Modal` implementation. It is supported fully in the legacy architecture. For the new architecture (Fabric renderer) it requires React Native `0.71` and up.
33
33
34
-
```javascript
35
-
import*asSentryfrom"@sentry/react-native";
36
-
37
-
Sentry.wrap(RootComponent);
38
-
39
-
Sentry.showFeedbackButton();
40
-
Sentry.hideFeedbackButton();
41
-
```
42
-
43
-
Note that [the root application component must be wrapped with `Sentry.wrap`](/platforms/react-native/#wrap-your-app) for the `showFeedbackForm` and `showFeedbackButton` methods to work. The methods depend on the React Native `Modal` implementation. It is supported fully in the legacy architecture. For the new architecture (Fabric renderer) it requires React Native `0.71` and up.
44
-
45
-
To configure the widget or the button you can use the `Sentry.feedbackIntegration({})` or add it to your Sentry initialization.
34
+
To configure the form you can use the `Sentry.feedbackIntegration({})` or add it to your Sentry initialization.
46
35
47
36
```javascript
48
37
import*asSentryfrom"@sentry/react-native";
@@ -106,7 +95,7 @@ Note that when the device is offline, the feedback will be stored locally and se
106
95
107
96
### Session Replay
108
97
109
-
The User Feedback widget integrates seamlessly with Session Replay. When the widget is opened, the SDK buffers up to 30 seconds of the user's session. If feedback is submitted, this replay is sent along with the feedback, allowing you to view both the feedback and the user's actions leading up to the feedback submission.
98
+
The User Feedback Form integrates seamlessly with Session Replay. When the widget is opened, the SDK buffers up to 30 seconds of the user's session. If feedback is submitted, this replay is sent along with the feedback, allowing you to view both the feedback and the user's actions leading up to the feedback submission.
0 commit comments