@@ -22,35 +22,33 @@ final _channel = const MethodChannel('example.flutter.sentry.io');
22
22
23
23
Future <void > main () async {
24
24
await setupSentry (() => runApp (
25
- SentryScreenshotWidget (
26
- child: DefaultAssetBundle (
27
- bundle: SentryAssetBundle (enableStructuredDataTracing: true ),
28
- child: MyApp (),
29
- ),
30
- ),
31
- ));
25
+ SentryScreenshotWidget (
26
+ child: DefaultAssetBundle (
27
+ bundle: SentryAssetBundle (enableStructuredDataTracing: true ),
28
+ child: MyApp (),
29
+ ),
30
+ ),
31
+ ));
32
32
}
33
33
34
34
Future <void > setupSentry (AppRunner appRunner) async {
35
- await SentryFlutter .init (
36
- (options) {
37
- options.dsn = _exampleDsn;
38
- options.tracesSampleRate = 1.0 ;
39
- options.reportPackages = false ;
40
- options.addInAppInclude ('sentry_flutter_example' );
41
- options.considerInAppFramesByDefault = false ;
42
- options.attachThreads = true ;
43
- options.enableWindowMetricBreadcrumbs = true ;
44
- options.addIntegration (LoggingIntegration ());
45
- options.attachScreenshot = true ;
46
- // We can enable Sentry debug logging during development. This is likely
47
- // going to log too much for your app, but can be useful when figuring out
48
- // configuration issues, e.g. finding out why your events are not uploaded.
49
- options.debug = true ;
50
- },
51
- // Init your App.
52
- appRunner: appRunner
53
- );
35
+ await SentryFlutter .init ((options) {
36
+ options.dsn = _exampleDsn;
37
+ options.tracesSampleRate = 1.0 ;
38
+ options.reportPackages = false ;
39
+ options.addInAppInclude ('sentry_flutter_example' );
40
+ options.considerInAppFramesByDefault = false ;
41
+ options.attachThreads = true ;
42
+ options.enableWindowMetricBreadcrumbs = true ;
43
+ options.addIntegration (LoggingIntegration ());
44
+ options.attachScreenshot = true ;
45
+ // We can enable Sentry debug logging during development. This is likely
46
+ // going to log too much for your app, but can be useful when figuring out
47
+ // configuration issues, e.g. finding out why your events are not uploaded.
48
+ options.debug = true ;
49
+ },
50
+ // Init your App.
51
+ appRunner: appRunner);
54
52
}
55
53
56
54
class MyApp extends StatefulWidget {
0 commit comments