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
Copy file name to clipboardExpand all lines: docs/product/dev-toolbar/index.mdx
+6-4Lines changed: 6 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,25 +9,25 @@ description: "Bring critical Sentry insights and tools directly into your web ap
9
9
[GitHub](https://github.com/getsentry/sentry-toolbar/issues) if you have any feedback or concerns.
10
10
</Alert>
11
11
12
-
Developers spend a lot of time troubleshooting their web apps on local, staging, and production environments. The Sentry Dev Toolbar pulls data from [sentry.io](http://sentry.io) and surfaces relevant actionable issues to you when you have the most context for understanding it: as you browse your own site. The Dev Toolbar is a floating widget in your web app, offering meaningful Sentry insights for the specific page being viewed through three different **page-aware** panels: Issues, Feedback and Feature Flags.
12
+
Developers spend a lot of time troubleshooting their web apps on local, staging, and production environments. The Sentry Dev Toolbar pulls data from [sentry.io](http://sentry.io) and surfaces relevant actionable issues to you when you have the most context for understanding it: as you browse your own site. The Dev Toolbar is a floating widget in your web app, offering meaningful Sentry insights for the specific page being viewed through three different **page-aware** panels: Issues, Feedback, and Feature Flags.
13
13
14
14

15
15
16
16
## Issues Panel
17
17
18
-
The issues panel shows you your highest priority frontend [issues](https://docs.sentry.io/product/issues/) for the page you are currently viewing. From the Dev Toolbar, you can quickly jump into specific issues in Sentry to get more detailed information and take action (for example, assign to a team member or mark as resolved). With the issues panel, you can browse the pages that are most important to your business and understand the top issues impacting your userbase.
18
+
The issues panel shows you your highest priority frontend [issues](https://docs.sentry.io/product/issues/) for the page you are currently viewing. From the Dev Toolbar, you can quickly jump into specific issues in Sentry to get more detailed information and take action (for example, assign to a team member or mark as resolved). With the issues panel, you can browse the pages that are most important to your business and understand the top issues impacting your user base.
19
19
20
20

21
21
22
22
## Feedback Panel
23
23
24
-
The feedback panel shows you the most recent user feedback messages for the page you are on, so you can more easily contextualize user feedback. The feedback can include misleading UX, broken links, typos, and so on, covering more bugs and suboptimal experiences than codethrown errors. The feedback panel works by pulling feedback messages from [Sentry’s User Feedback Widget](https://docs.sentry.io/product/user-feedback/#user-feedback-widget).
24
+
The feedback panel shows you the most recent user feedback messages for the page you are on, so you can more easily contextualize user feedback. The feedback can include misleading UX, broken links, typos, and so on, covering more bugs and suboptimal experiences than code-thrown errors. The feedback panel works by pulling feedback messages from [Sentry’s User Feedback Widget](https://docs.sentry.io/product/user-feedback/#user-feedback-widget).
25
25
26
26

27
27
28
28
## Feature Flags Panel
29
29
30
-
Feature flags are a powerful tool that allow you to control the visibility of features in your app, enabling you to ship, test, and experiment with confidence. The feature flag panel allows you to quickly view and override feature flags that your team has enabled for your web application. You can override any feature flag to be ‘true’ or ‘false’ for your browser session, so you can verify its behavior and observe the impact it might have on errors. Learn more about how to [configure the feature flag panel](/product/dev-toolbar/setup/#implement-feature-flag-adapter).
30
+
Feature flags are a powerful tool that allow you to control the visibility of features in your app, enabling you to ship, test, and experiment with confidence. The feature flag panel allows you to quickly view and override feature flags locally that your team has enabled for your web application. You can override any feature flag to be ‘true’ or ‘false’ for your browser session, so you can verify its behavior and observe the impact it might have on errors. Learn more about how to [configure the feature flag panel](/product/dev-toolbar/setup/#implement-feature-flag-adapter).
31
31
32
32
[Learn more](/product/explore/feature-flags/) about what data Sentry can track related to your feature flagging system.
33
33
@@ -48,3 +48,5 @@ You'll need to add your domain URL to Allowed Origins on Sentry's Dev Toolbar se
48
48

49
49
50
50
Learn more about [deploying the toolbar to different environments](/product/dev-toolbar/setup/#deploying-to-production--dev-environments), and [conditionally inserting the toolbar script tag](/product/dev-toolbar/setup/#conditionally-inserting-script-tag).
Copy file name to clipboardExpand all lines: docs/product/dev-toolbar/setup.mdx
+12-12Lines changed: 12 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,11 +12,11 @@ description: "Get started with Sentry's Dev Toolbar, bringing critical Sentry in
12
12
## Set Up Your Web App
13
13
14
14
<Alerttitle="Note"level="warning">
15
-
Enabling performance is a prerequisite for having page-aware panels, as it allows us to collect page-specific issues and feedback through transactions.
15
+
[Enabling tracing](/platforms/javascript/tracing/) is a prerequisite for having page-aware panels, as it allows us to collect page-specific issues and feedback through transactions.
16
16
</Alert>
17
17
18
-
You need to do two things to get the toolbar rendered on the page:
19
-
1. Add or dynamically inject `<script defer src="https://browser.sentry-cdn.com/sentry-toolbar/latest/toolbar.min.js"></script>` into your web app. This script uses the `defer` attribute so that it does not block document parsing. The script tag can be inserted at the bottom of the page so it doesn’t block other critical javascript.
18
+
You need to complete two steps to get the toolbar rendered on the page:
19
+
1. Add or dynamically inject `<script defer src="https://browser.sentry-cdn.com/sentry-toolbar/latest/toolbar.min.js"></script>` into your web app. This script uses the `defer` attribute so that it does not block document parsing. The script tag can be inserted at the bottom of the page so it doesn’t block other critical Javascript.
20
20
2. Call `window.SentryToolbar.init(initConfig)` to set up a toolbar instance on each page where you want to see the Dev Toolbar.
21
21
```html
22
22
<html>
@@ -33,7 +33,7 @@ You need to do two things to get the toolbar rendered on the page:
33
33
34
34
### Unmounting The Toolbar
35
35
36
-
If you have called `SentryToolbar.init({...})` to render the toolbar but now want to manually remove or unmount it from the page you can call the cleanup function that is returned from `init()`. This will unmount all the injected HTML and CSS. Login credentials will not be removed, so you can re-insert the toolbar and still be authenticated.
36
+
If you have called `SentryToolbar.init({...})` to render the toolbar, but now want to manually remove or unmount it from the page, you can call the cleanup function that is returned from `init()`. This will unmount all the injected HTML and CSS. Login credentials will not be removed, so you can re-insert the toolbar and still be authenticated.
@@ -46,9 +46,9 @@ If you have called `SentryToolbar.init({...})` to render the toolbar but now wan
46
46
47
47
## Implement Feature Flag Adapter
48
48
49
-
In order to integrate your Feature Flagging platform with the Dev Toolbar you will need an Adapter that can read flag data from your provider, and also store and retrieve a list of overrides to apply to your local browser session.
49
+
In order to integrate your Feature Flagging platform with the Dev Toolbar, you will need an Adapter that can read flag data from your provider, and also store and retrieve a list of overrides to apply to your local browser session.
50
50
51
-
We plan to create adapters for OpenFeature and LaunchDarkly, coming soon!
51
+
We plan to create adapters for OpenFeature and LaunchDarkly soon!
52
52
53
53
The interface you need to implement for an Adapter is:
54
54
```javascript
@@ -103,12 +103,12 @@ window.SentryToolbar.init({
103
103
|`organizationSlug`|`string`| The organization that users should login to. For example \`acme\`|*Required Value*|
104
104
|`projectIdOrSlug`|`string \| number`| The project for which this website/webapp is associated. |*Required Value*|
105
105
|`environment (optional)`|`string \| string[] \| undefined`| The environment of this deployment. Used to narrow search results in the Toolbar UI. Set to \`undefined\` or \`””\` or \`\[\]\` if you want to see results from all environments. |`undefined`|
106
-
|`placement (optional)`|`‘right-edge’ \| ‘bottom-right-corner’`| Where to render the toolbar on the screen. |`”right-edge”`|
107
-
|`theme (optional)`|`‘system’ \| ‘dark’ \| ‘light’`| Whether to use dark or light mode. |`”system”`|
106
+
|`placement (optional)`|`'right-edge' \| 'bottom-right-corner'`| Where to render the toolbar on the screen. |`"right-edge"`|
107
+
|`theme (optional)`|`'system' \| 'dark' \| 'light'`| Whether to use dark or light mode. |`"system"`|
108
108
|`featureFlags (optional)`|`FeatureFlagAdapter \| undefined`| See [Implement FeatureFlagAdapter](/product/dev-toolbar/setup//#implement-feature-flag-adapter) above |`undefined`|
109
-
|`sentryOrigin (optional)`|`string \| undefined`| The origin where sentry can be found. Used for loading the connection to sentry, and generating links to the website. For example: \`"[https://acme.sentry.io](https://acme.sentry.io)"\`|`"https://sentry.io"`|
110
-
|`domId (optional)`|`string \| undefined`| The \`id\` given to the \<div\> that is created to contain the toolbar html. |`”sentry-toolbar”`|
111
-
|`debug (optional)`|`string \| undefined`| A comma separated string of debug targets to enable. Example: `”logging,state”` If the list contains ”all” or ”true” then all targets will be enabled. Valid targets: `”logging” ”login-success” “settings” ”state”`|`undefined`|
109
+
|`sentryOrigin (optional)`|`string \| undefined`| The origin where Sentry can be found. Used for loading the connection to Sentry, and generating links to the website. For example: \`"[https://acme.sentry.io]"\`|`"https://sentry.io"`|
110
+
|`domId (optional)`|`string \| undefined`| The \`id\` given to the \<div\> that is created to contain the toolbar html. |`"sentry-toolbar"`|
111
+
|`debug (optional)`|`string \| undefined`| A comma separated string of debug targets to enable. Example: `"logging,state"` If the list contains ”all” or ”true” then all targets will be enabled. Valid targets: `"logging" "login-success" "settings" "state"`|`undefined`|
112
112
|`mountPoint (optional)`|`HTMLElement \| () => HTMLElement \| undefined`| Where to mount the toolbar in the DOM. |`document.body`|
113
113
114
114
@@ -136,7 +136,7 @@ if (isDev || isEmployeeInProd) {
136
136
}
137
137
```
138
138
139
-
If the toolbar `<script>` is accidentally included on your site, and `SentryToolbar.init()` is called, then a "Login to Sentry" button will be visible to the public. This is not ideal, but your data in Sentry will still be safe as users outside of your sentry organization will not be able to authenticate themselves.
139
+
If the toolbar `<script>` is accidentally included on your site, and `SentryToolbar.init()` is called, then a "Login to Sentry" button will be visible to the public. This is not ideal, but your data in Sentry will still be safe as users outside of your Sentry organization will not be able to authenticate themselves.
0 commit comments