1
1
import * as Sentry from '@nativescript-community/sentry' ;
2
+ import * as Tracing from '@nativescript-community/sentry/tracing' ;
2
3
import { Application , Trace , Utils } from '@nativescript/core' ;
3
4
import { on as applicationOn , launchEvent } from '@nativescript/core/application' ;
4
5
import Vue from 'nativescript-vue' ;
@@ -13,14 +14,24 @@ async function startSentry() {
13
14
Sentry . init ( {
14
15
dsn : SENTRY_DSN ,
15
16
debug : true ,
17
+ enablePerformanceV2 : true ,
18
+ release : `${ __APP_ID__ } @${ __APP_VERSION__ } +${ __APP_BUILD_NUMBER__ } ` ,
19
+ dist : `${ __APP_BUILD_NUMBER__ } .${ __ANDROID__ ? 'android' : 'ios' } ` ,
16
20
flushSendEvent : true ,
17
21
enableNativeCrashHandling : true ,
18
- enableAutoPerformanceTracking : false ,
19
- enableAutoSessionTracking : false ,
20
- enablePerformanceV2 : true ,
21
22
attachScreenshot : true ,
22
- release : `${ __APP_ID__ } @${ __APP_VERSION__ } +${ __APP_BUILD_NUMBER__ } ` ,
23
- dist : `${ __APP_BUILD_NUMBER__ } .${ __ANDROID__ ? 'android' : 'ios' } `
23
+ tracesSampleRate : 1.0 ,
24
+ sampleRate : 1.0 ,
25
+ enableAutoPerformanceTracking : true ,
26
+ enableAutoSessionTracking : true ,
27
+ integrations : [
28
+ new Tracing . NativescriptTracing ( {
29
+ enableAppStartTracking : true ,
30
+ enableNativeFramesTracking : true ,
31
+ // routingInstrumentation: HttpService.sentryTracing,
32
+ enableStallTracking : true ,
33
+ } ) ,
34
+ ] ,
24
35
} ) ;
25
36
setTimeout ( ( ) => {
26
37
Sentry . withScope ( scope => {
0 commit comments