Skip to content

Commit 313d8c6

Browse files
committed
Add user feedback option to JavaScript and Svelte onboarding guides
1 parent 88b3a07 commit 313d8c6

File tree

3 files changed

+62
-2
lines changed

3 files changed

+62
-2
lines changed

docs/platforms/javascript/guides/react/index.mdx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ categories:
1616
Choose the features you want to configure, and this guide will show you how:
1717

1818
<OnboardingOptionButtons
19-
options={["error-monitoring", "performance", "session-replay"]}
19+
options={["error-monitoring", "performance", "session-replay", "user-feedback"]}
2020
/>
2121

2222
<PlatformContent includePath="getting-started-features-expandable" />
@@ -63,6 +63,12 @@ Sentry.init({
6363
// ___PRODUCT_OPTION_START___ session-replay
6464
Sentry.replayIntegration(),
6565
// ___PRODUCT_OPTION_END___ session-replay
66+
// ___PRODUCT_OPTION_START___ user-feedback
67+
Sentry.feedbackIntegration({
68+
// Additional SDK configuration goes in here, for example:
69+
colorScheme: "system",
70+
}),
71+
// ___PRODUCT_OPTION_END___ user-feedback
6672
],
6773

6874
// ___PRODUCT_OPTION_START___ performance

docs/platforms/javascript/guides/svelte/index.mdx

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ categories:
1414
Choose the features you want to configure, and this guide will show you how:
1515

1616
<OnboardingOptionButtons
17-
options={["error-monitoring", "performance", "session-replay"]}
17+
options={["error-monitoring", "performance", "session-replay", "user-feedback"]}
1818
/>
1919

2020
<PlatformContent includePath="getting-started-features-expandable" />
@@ -61,6 +61,12 @@ Sentry.init({
6161
// ___PRODUCT_OPTION_START___ session-replay
6262
Sentry.replayIntegration(),
6363
// ___PRODUCT_OPTION_END___ session-replay
64+
// ___PRODUCT_OPTION_START___ user-feedback
65+
Sentry.feedbackIntegration({
66+
// Additional SDK configuration goes in here, for example:
67+
colorScheme: "system",
68+
}),
69+
// ___PRODUCT_OPTION_END___ user-feedback
6470
],
6571
// ___PRODUCT_OPTION_START___ performance
6672

@@ -108,6 +114,12 @@ Sentry.init({
108114
// ___PRODUCT_OPTION_START___ session-replay
109115
Sentry.replayIntegration(),
110116
// ___PRODUCT_OPTION_END___ session-replay
117+
// ___PRODUCT_OPTION_START___ user-feedback
118+
Sentry.feedbackIntegration({
119+
// Additional SDK configuration goes in here, for example:
120+
colorScheme: "system",
121+
}),
122+
// ___PRODUCT_OPTION_END___ user-feedback
111123
],
112124
// ___PRODUCT_OPTION_START___ performance
113125

platform-includes/getting-started-config/javascript.mdx

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,21 @@ Sentry.init({
1616
// if your build tool supports it.
1717
release: "[email protected]",
1818
integrations: [
19+
// ___PRODUCT_OPTION_START___ performance
1920
Sentry.browserTracingIntegration(),
21+
// ___PRODUCT_OPTION_END___ performance
22+
// ___PRODUCT_OPTION_START___ session-replay
2023
Sentry.replayIntegration(),
24+
// ___PRODUCT_OPTION_END___ session-replay
25+
// ___PRODUCT_OPTION_START___ user-feedback
26+
Sentry.feedbackIntegration({
27+
// Additional SDK configuration goes in here, for example:
28+
colorScheme: "system",
29+
}),
30+
// ___PRODUCT_OPTION_END___ user-feedback
2131
],
2232

33+
// ___PRODUCT_OPTION_START___ performance
2334
// Set tracesSampleRate to 1.0 to capture 100%
2435
// of transactions for tracing.
2536
// We recommend adjusting this value in production
@@ -29,13 +40,16 @@ Sentry.init({
2940

3041
// Set `tracePropagationTargets` to control for which URLs trace propagation should be enabled
3142
tracePropagationTargets: ["localhost", /^https:\/\/yourserver\.io\/api/],
43+
// ___PRODUCT_OPTION_END___ performance
3244

45+
// ___PRODUCT_OPTION_START___ session-replay
3346
// Capture Replay for 10% of all sessions,
3447
// plus for 100% of sessions with an error
3548
// Learn more at
3649
// https://docs.sentry.io/platforms/javascript/session-replay/configuration/#general-integration-configuration
3750
replaysSessionSampleRate: 0.1,
3851
replaysOnErrorSampleRate: 1.0,
52+
// ___PRODUCT_OPTION_END___ session-replay
3953
});
4054
```
4155

@@ -58,10 +72,21 @@ Sentry.init({
5872
// if your build tool supports it.
5973
release: "[email protected]",
6074
integrations: [
75+
// ___PRODUCT_OPTION_START___ performance
6176
Sentry.browserTracingIntegration(),
77+
// ___PRODUCT_OPTION_END___ performance
78+
// ___PRODUCT_OPTION_START___ session-replay
6279
Sentry.replayIntegration(),
80+
// ___PRODUCT_OPTION_END___ session-replay
81+
// ___PRODUCT_OPTION_START___ user-feedback
82+
Sentry.feedbackIntegration({
83+
// Additional SDK configuration goes in here, for example:
84+
colorScheme: "system",
85+
}),
86+
// ___PRODUCT_OPTION_END___ user-feedback
6387
],
6488
89+
// ___PRODUCT_OPTION_START___ performance
6590
// Set tracesSampleRate to 1.0 to capture 100%
6691
// of transactions for tracing.
6792
// We recommend adjusting this value in production
@@ -71,13 +96,16 @@ Sentry.init({
7196
7297
// Set `tracePropagationTargets` to control for which URLs trace propagation should be enabled
7398
tracePropagationTargets: ["localhost", /^https:\/\/yourserver\.io\/api/],
99+
// ___PRODUCT_OPTION_END___ performance
74100
101+
// ___PRODUCT_OPTION_START___ session-replay
75102
// Capture Replay for 10% of all sessions,
76103
// plus for 100% of sessions with an error
77104
// Learn more at
78105
// https://docs.sentry.io/platforms/javascript/session-replay/configuration/#general-integration-configuration
79106
replaysSessionSampleRate: 0.1,
80107
replaysOnErrorSampleRate: 1.0,
108+
// ___PRODUCT_OPTION_END___ session-replay
81109
});
82110
};
83111
</script>
@@ -102,10 +130,21 @@ Sentry.init({
102130
// if your build tool supports it.
103131
release: "[email protected]",
104132
integrations: [
133+
// ___PRODUCT_OPTION_START___ performance
105134
Sentry.browserTracingIntegration(),
135+
// ___PRODUCT_OPTION_END___ performance
136+
// ___PRODUCT_OPTION_START___ session-replay
106137
Sentry.replayIntegration(),
138+
// ___PRODUCT_OPTION_END___ session-replay
139+
// ___PRODUCT_OPTION_START___ user-feedback
140+
Sentry.feedbackIntegration({
141+
// Additional SDK configuration goes in here, for example:
142+
colorScheme: "system",
143+
}),
144+
// ___PRODUCT_OPTION_END___ user-feedback
107145
],
108146
147+
// ___PRODUCT_OPTION_START___ performance
109148
// Set tracesSampleRate to 1.0 to capture 100%
110149
// of transactions for tracing.
111150
// We recommend adjusting this value in production
@@ -115,13 +154,16 @@ Sentry.init({
115154
116155
// Set `tracePropagationTargets` to control for which URLs trace propagation should be enabled
117156
tracePropagationTargets: ["localhost", /^https:\/\/yourserver\.io\/api/],
157+
// ___PRODUCT_OPTION_END___ performance
118158
159+
// ___PRODUCT_OPTION_START___ session-replay
119160
// Capture Replay for 10% of all sessions,
120161
// plus for 100% of sessions with an error
121162
// Learn more at
122163
// https://docs.sentry.io/platforms/javascript/session-replay/configuration/#general-integration-configuration
123164
replaysSessionSampleRate: 0.1,
124165
replaysOnErrorSampleRate: 1.0,
166+
// ___PRODUCT_OPTION_END___ session-replay
125167
});
126168
</script>
127169
```

0 commit comments

Comments
 (0)