2021-10-31 14:37:57 +01:00
|
|
|
import {VERSION} from './version.json'
|
|
|
|
|
2021-10-26 20:53:17 +02:00
|
|
|
export default async function setupSentry(app, router) {
|
|
|
|
const Sentry = await import('@sentry/vue')
|
|
|
|
const {Integrations} = await import('@sentry/tracing')
|
|
|
|
|
|
|
|
Sentry.init({
|
2021-10-31 14:37:57 +01:00
|
|
|
release: VERSION,
|
2021-10-26 20:53:17 +02:00
|
|
|
app,
|
|
|
|
dsn: window.SENTRY_DSN,
|
|
|
|
integrations: [
|
|
|
|
new Integrations.BrowserTracing({
|
|
|
|
routingInstrumentation: Sentry.vueRouterInstrumentation(router),
|
|
|
|
tracingOrigins: ['localhost', /^\//],
|
|
|
|
}),
|
|
|
|
],
|
|
|
|
tracesSampleRate: 1.0,
|
|
|
|
})
|
|
|
|
}
|