Skip to content

Commit

Permalink
update documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
0Calories committed Oct 8, 2024
1 parent 5374baa commit 3a65227
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
11 changes: 10 additions & 1 deletion packages/babel-plugin-component-annotate/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,14 @@ Using pnpm:
pnpm add @sentry/babel-plugin-component-annotate --save-dev
```

## Options

### `ignoreComponents`

Type: `string[]`

A list of strings representing the names of components to ignore. The plugin will not perform apply `data-sentry` annotations on the DOM element for these components.

## Example

```js
Expand All @@ -57,7 +65,8 @@ pnpm add @sentry/babel-plugin-component-annotate --save-dev

plugins: [
// Put this plugin before any other plugins you have that transform JSX code
['@sentry/babel-plugin-component-annotate']
// The options are set by providing an object as the second element in the array, but not required
['@sentry/babel-plugin-component-annotate', {ignoreComponents: ['Foo', 'Bar']}]
],
}
```
Expand Down
2 changes: 1 addition & 1 deletion packages/dev-utils/src/generate-documentation-table.ts
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ type IncludeEntry = {
name: "ignoreComponents",
type: "string[]",
fullDescription:
"A list of strings representing the names of components to ignore. The plugin will not perform apply `data-sentry` annotations on the DOM element for this component.",
"A list of strings representing the names of components to ignore. The plugin will not perform apply `data-sentry` annotations on the DOM element for these components.",
supportedBundlers: ["webpack", "vite", "rollup"],
},
// TODO: Support this option in the future
Expand Down

0 comments on commit 3a65227

Please sign in to comment.