Skip to content

Commit 9544176

Browse files
authored
chore(vue): Update README for Vue 3 (#3832)
1 parent e5e8493 commit 9544176

File tree

1 file changed

+15
-2
lines changed

1 file changed

+15
-2
lines changed

packages/vue/README.md

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,22 @@
1717
This package is a wrapper around `@sentry/browser`, with added functionality related to Vue.js. All methods available in
1818
`@sentry/browser` can be imported from `@sentry/vue`.
1919

20-
It targets Vue version `2.x`. Support for `3.x` is tracked by [GitHub issue #2925](https://github.com/getsentry/sentry-javascript/issues/2925).
20+
To use this SDK, call `Sentry.init(options)` as early in your application as possible.
2121

22-
To use this SDK, call `Sentry.init(options)` before you create a new Vue instance.
22+
### Vue 3
23+
24+
```javascript
25+
const app = createApp({
26+
// ...
27+
});
28+
29+
Sentry.init({
30+
app,
31+
dsn: '__PUBLIC_DSN__',
32+
});
33+
```
34+
35+
### Vue 2
2336

2437
```javascript
2538
import Vue from 'vue'

0 commit comments

Comments
 (0)