Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Add section explaining possible breadcrumb levels
  • Loading branch information
Luca Forstner committed May 30, 2022
commit 52ec5bc2cc05d8b797633c79c10c1dfc17d843bd
2 changes: 2 additions & 0 deletions src/includes/set-level/javascript.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ To set the level out of scope, you can call `captureMessage()` per event:
Sentry.captureMessage("this is a debug message", "debug");
```

Available levels are `"fatal"`, `"critical"`, `"error"`, `"warning"`, `"log"`, `"info"`, and `"debug"`.

To set the level within scope, you can call `setLevel()`:

```javascript
Expand Down
6 changes: 6 additions & 0 deletions src/platforms/common/enriching-events/breadcrumbs.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,12 @@ The available breadcrumb keys are `type`, `category`, `message`, `level`, `times

</PlatformSection>

<PlatformSection supported={["javascript", "node"]}>

You can choose from the following breadcrumb log levels: `"fatal"`, `"critical"`, `"error"`, `"warning"`, `"log"`, `"info"`, and `"debug"`.

</PlatformSection>

<PlatformSection notSupported={["native", "unreal"]}>

## Automatic Breadcrumbs
Expand Down
4 changes: 2 additions & 2 deletions src/platforms/javascript/common/troubleshooting/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -395,12 +395,12 @@ document.body.addEventListener(
if (event.target.tagName === "IMG") {
Sentry.captureMessage(
`Failed to load image: ${event.target.src}`,
"warning" // message severity level
"warning"
);
} else if (event.target.tagName === "LINK") {
Sentry.captureMessage(
`Failed to load css: ${event.target.href}`,
"warning" // message severity level
"warning"
);
}
},
Expand Down