@nativescript-community/sentry 4.6.6 → 4.6.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md DELETED
@@ -1,358 +0,0 @@
1
- # Change Log
2
-
3
- All notable changes to this project will be documented in this file.
4
- See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
-
6
- ## [4.6.6](https://github.com/nativescript-community/sentry/compare/v4.6.5...v4.6.6) (2022-12-09)
7
-
8
- **Note:** Version bump only for package @nativescript-community/sentry
9
-
10
-
11
-
12
-
13
-
14
- ## [4.6.5](https://github.com/nativescript-community/sentry/compare/v4.6.4...v4.6.5) (2022-12-09)
15
-
16
- **Note:** Version bump only for package @nativescript-community/sentry
17
-
18
-
19
-
20
-
21
-
22
- ## [4.6.4](https://github.com/nativescript-community/sentry/compare/v4.6.3...v4.6.4) (2022-12-09)
23
-
24
-
25
- ### Bug Fixes
26
-
27
- * **android:** native sdk update ([633dd3a](https://github.com/nativescript-community/sentry/commit/633dd3aebed875bb7fb2e6c08eeca53c208756ea))
28
- * **ios:** native sdk update with build fix ([b73b021](https://github.com/nativescript-community/sentry/commit/b73b021af47a59b40156503d1776928953d505ed))
29
-
30
-
31
-
32
-
33
-
34
- ## [4.6.3](https://github.com/nativescript-community/sentry/compare/v4.6.2...v4.6.3) (2022-12-08)
35
-
36
- **Note:** Version bump only for package @nativescript-community/sentry
37
-
38
-
39
-
40
-
41
-
42
- ## [4.6.2](https://github.com/nativescript-community/sentry/compare/v4.6.1...v4.6.2) (2022-10-28)
43
-
44
-
45
- ### Bug Fixes
46
-
47
- * **android:** native api usage fix ([ed64d44](https://github.com/nativescript-community/sentry/commit/ed64d449627eedec1c92233ac9b06baa97c0db70))
48
-
49
-
50
-
51
-
52
-
53
- ## [4.6.1](https://github.com/nativescript-community/sentry/compare/v4.6.0...v4.6.1) (2022-10-28)
54
-
55
-
56
- ### Bug Fixes
57
-
58
- * **android:** native api usage fix ([4d5ab0c](https://github.com/nativescript-community/sentry/commit/4d5ab0cc513306291086f249d4a93677419f06fc))
59
- * **android:** native api usage fix ([e8be88d](https://github.com/nativescript-community/sentry/commit/e8be88d98ae8a9867e426063de6ab0a39ec3a0e5))
60
- * **android:** native-api-usage fix ([c69b747](https://github.com/nativescript-community/sentry/commit/c69b74712ef4fb9e9d701fd6c2fa4d40d4ad09c7))
61
-
62
-
63
-
64
-
65
-
66
- # [4.6.0](https://github.com/nativescript-community/sentry/compare/v3.1.5...v4.6.0) (2022-10-19)
67
-
68
-
69
- ### Bug Fixes
70
-
71
- * **android:** use latest gradle plugin requiring gradle 7+ ([7a29368](https://github.com/nativescript-community/sentry/commit/7a29368cb533548cbf2d5aee02b9d869c3181be0))
72
- * improving integration ([7e8be4e](https://github.com/nativescript-community/sentry/commit/7e8be4e2d37f29d07b155d9c0f2e028c858f1039))
73
-
74
-
75
- ### Features
76
-
77
- * bump to latest JS/native SDKs ([d63d12a](https://github.com/nativescript-community/sentry/commit/d63d12a837c7b0da7ed170360716169d9d79d3e5))
78
-
79
-
80
-
81
-
82
-
83
- ## [3.1.5](https://github.com/nativescript-community/sentry/compare/v3.1.4...v3.1.5) (2022-05-12)
84
-
85
-
86
- ### Bug Fixes
87
-
88
- * **android:** native-api-usage fix ([a4075e6](https://github.com/nativescript-community/sentry/commit/a4075e66853149a2d291158684646abb8f96e271))
89
-
90
-
91
-
92
-
93
-
94
- ## [3.1.4](https://github.com/nativescript-community/sentry/compare/v3.1.3...v3.1.4) (2022-05-05)
95
-
96
-
97
- ### Bug Fixes
98
-
99
- * **android:** native api usage fix ([052bab0](https://github.com/nativescript-community/sentry/commit/052bab0464e8a88882beb286ff2f955a436adb49))
100
-
101
-
102
-
103
-
104
-
105
- ## [3.1.3](https://github.com/nativescript-community/sentry/compare/v3.1.2...v3.1.3) (2022-03-24)
106
-
107
- **Note:** Version bump only for package @nativescript-community/sentry
108
-
109
-
110
-
111
-
112
-
113
- ## [3.1.2](https://github.com/nativescript-community/sentry/compare/v3.1.1...v3.1.2) (2022-03-24)
114
-
115
- **Note:** Version bump only for package @nativescript-community/sentry
116
-
117
-
118
-
119
-
120
-
121
- ## [3.1.1](https://github.com/nativescript-community/sentry/compare/v3.1.0...v3.1.1) (2022-03-03)
122
-
123
-
124
- ### Bug Fixes
125
-
126
- * **android:** rollback gradle plugin version as it breaks build in some apps ([c1ccbb2](https://github.com/nativescript-community/sentry/commit/c1ccbb231ddf6f6b00816e8aeb4896e43e1368be))
127
-
128
-
129
-
130
-
131
-
132
- # [3.1.0](https://github.com/nativescript-community/sentry/compare/v3.0.3...v3.1.0) (2022-02-18)
133
-
134
-
135
- ### Features
136
-
137
- * update to latest Sentry SDK ([e863de2](https://github.com/nativescript-community/sentry/commit/e863de2aa339097b79665f7169f129369f5355f8))
138
-
139
-
140
-
141
-
142
-
143
- ## [3.0.3](https://github.com/nativescript-community/sentry/compare/v3.0.2...v3.0.3) (2022-01-25)
144
-
145
-
146
- ### Bug Fixes
147
-
148
- * **android:** build fix by adding mavenCentral ([2d61ffc](https://github.com/nativescript-community/sentry/commit/2d61ffc755ef7fe396ae7a16e585d461bd025eb3))
149
-
150
-
151
-
152
-
153
-
154
- ## [3.0.2](https://github.com/nativescript-community/sentry/compare/v3.0.1...v3.0.2) (2022-01-24)
155
-
156
- **Note:** Version bump only for package @nativescript-community/sentry
157
-
158
-
159
-
160
-
161
-
162
- ## [3.0.1](https://github.com/nativescript-community/sentry/compare/v3.0.0...v3.0.1) (2021-10-31)
163
-
164
-
165
- ### Bug Fixes
166
-
167
- * **android:** gradle 7.0 support ([23a60b4](https://github.com/nativescript-community/sentry/commit/23a60b49b6ac26c4930ef153d38026a2ceadf522))
168
-
169
-
170
-
171
-
172
-
173
- # [3.0.0](https://github.com/nativescript-community/sentry/compare/v2.1.1...v3.0.0) (2021-09-21)
174
-
175
- **Note:** Version bump only for package @nativescript-community/sentry
176
-
177
-
178
-
179
-
180
-
181
- ## [2.1.1](https://github.com/nativescript-community/sentry/compare/v2.1.0...v2.1.1) (2021-09-21)
182
-
183
-
184
- ### Bug Fixes
185
-
186
- * move to latest SDKs ([34e37fd](https://github.com/nativescript-community/sentry/commit/34e37fdea216741f76a99bf748c036b5319e3218))
187
-
188
-
189
-
190
-
191
-
192
- # [2.1.0](https://github.com/nativescript-community/sentry/compare/v2.0.8...v2.1.0) (2021-02-24)
193
-
194
-
195
- ### Features
196
-
197
- * update to latest SDKs REQUIRES Sentry 20.6.0 + ([b4db1a9](https://github.com/nativescript-community/sentry/commit/b4db1a95f0f265472512e1ee10ef39d965f94e44))
198
-
199
-
200
-
201
-
202
-
203
- ## [2.0.8](https://github.com/nativescript-community/sentry/compare/v2.0.7...v2.0.8) (2020-11-23)
204
-
205
- **Note:** Version bump only for package @nativescript-community/sentry
206
-
207
-
208
-
209
-
210
-
211
- ## [2.0.7](https://github.com/nativescript-community/sentry/compare/v2.0.6...v2.0.7) (2020-11-22)
212
-
213
- **Note:** Version bump only for package @nativescript-community/sentry
214
-
215
-
216
-
217
-
218
-
219
- ## [2.0.6](https://github.com/nativescript-community/sentry/compare/v2.0.5...v2.0.6) (2020-11-19)
220
-
221
- **Note:** Version bump only for package @nativescript-community/sentry
222
-
223
-
224
-
225
-
226
-
227
- ## [2.0.5](https://github.com/nativescript-community/sentry/compare/v2.0.4...v2.0.5) (2020-11-02)
228
-
229
-
230
- ### Bug Fixes
231
-
232
- * N 7 update ([1a03eec](https://github.com/nativescript-community/sentry/commit/1a03eeccc2b344e1fca4c23ce1a91b1c77df4354))
233
-
234
-
235
-
236
-
237
-
238
- ## [2.0.4](https://github.com/nativescript-community/sentry/compare/v2.0.3...v2.0.4) (2020-11-02)
239
-
240
- **Note:** Version bump only for package @nativescript-community/sentry
241
-
242
-
243
-
244
-
245
-
246
- ## [2.0.3](https://github.com/nativescript-community/sentry/compare/v2.0.2...v2.0.3) (2020-09-02)
247
-
248
- **Note:** Version bump only for package @nativescript-community/sentry
249
-
250
-
251
-
252
-
253
-
254
- ## [2.0.2](https://github.com/nativescript-community/sentry/compare/v2.0.1...v2.0.2) (2020-09-02)
255
-
256
- **Note:** Version bump only for package @nativescript-community/sentry
257
-
258
-
259
-
260
-
261
-
262
- ## [2.0.1](https://github.com/nativescript-community/sentry/compare/v2.0.0...v2.0.1) (2020-09-02)
263
-
264
- **Note:** Version bump only for package @nativescript-community/sentry
265
-
266
-
267
-
268
-
269
-
270
- # [2.0.0](https://github.com/nativescript-community/sentry/compare/v1.0.0...v2.0.0) (2020-07-22)
271
-
272
- **Note:** Version bump only for package @nativescript-community/sentry
273
-
274
-
275
-
276
-
277
-
278
- # [1.0.0](https://github.com/nativescript-community/sentry/compare/v0.0.9...v1.0.0) (2020-07-22)
279
-
280
- **Note:** Version bump only for package @nativescript-community/sentry
281
-
282
-
283
-
284
-
285
-
286
- ## [0.0.9](https://github.com/nativescript-community/sentry/compare/v0.0.8...v0.0.9) (2020-07-22)
287
-
288
-
289
- ### Bug Fixes
290
-
291
- * update to latest SDK ([3f02271](https://github.com/nativescript-community/sentry/commit/3f02271bda4ca548606fa91ce50cd5ace198e7ef))
292
-
293
-
294
-
295
-
296
-
297
- ## [0.0.8](https://github.com/nativescript-community/sentry/compare/v0.0.7...v0.0.8) (2020-06-22)
298
-
299
- **Note:** Version bump only for package @nativescript-community/sentry
300
-
301
-
302
-
303
-
304
-
305
- ## [0.0.7](https://github.com/nativescript-community/sentry/compare/v0.0.6...v0.0.7) (2020-04-02)
306
-
307
- **Note:** Version bump only for package @nativescript-community/sentry
308
-
309
-
310
-
311
-
312
-
313
- ## [0.0.6](https://github.com/nativescript-community/sentry/compare/v0.0.5...v0.0.6) (2020-04-01)
314
-
315
-
316
- ### Bug Fixes
317
-
318
- * major update of the android sdk ([dd415cb](https://github.com/nativescript-community/sentry/commit/dd415cb55c35230063ce860e72c64baa6415d5a4))
319
-
320
-
321
-
322
-
323
-
324
- ## [0.0.5](https://github.com/nativescript-community/sentry/compare/v0.0.4...v0.0.5) (2020-01-29)
325
-
326
- **Note:** Version bump only for package @nativescript-community/sentry
327
-
328
-
329
-
330
-
331
-
332
- ## [0.0.4](https://github.com/nativescript-community/sentry/compare/v0.0.3...v0.0.4) (2020-01-29)
333
-
334
- **Note:** Version bump only for package @nativescript-community/sentry
335
-
336
-
337
-
338
-
339
-
340
- ## [0.0.3](https://github.com/nativescript-community/sentry/compare/v0.0.2...v0.0.3) (2020-01-27)
341
-
342
- **Note:** Version bump only for package @nativescript-community/sentry
343
-
344
-
345
-
346
-
347
-
348
- ## [0.0.2](https://github.com/nativescript-community/sentry/compare/v0.0.1...v0.0.2) (2020-01-27)
349
-
350
- **Note:** Version bump only for package @nativescript-community/sentry
351
-
352
-
353
-
354
-
355
-
356
- ## 0.0.1 (2020-01-27)
357
-
358
- **Note:** Version bump only for package @nativescript-community/sentry
package/backend.d.ts DELETED
@@ -1,105 +0,0 @@
1
- import { BrowserOptions } from '@sentry/browser';
2
- import { BaseBackend } from '@sentry/core';
3
- import { CaptureContext, Event, EventHint, Severity, Transport } from '@sentry/types';
4
- import { SyncPromise } from '@sentry/utils';
5
- /**
6
- * Configuration options for the Sentry Nativescript SDK.
7
- * @see NativescriptFrontend for more information.
8
- */
9
- export interface NativescriptOptions extends BrowserOptions {
10
- /**
11
- * Enables native transport + device info + offline caching.
12
- * Be careful, disabling this also breaks automatic release setting.
13
- * This means you have to manage setting the release yourself.
14
- * Defaults to `true`.
15
- */
16
- enableNative?: boolean;
17
- enableAutoSessionTracking?: boolean;
18
- /**
19
- * Enables native crashHandling. This only works if `enableNative` is `true`.
20
- * Defaults to `true`.
21
- */
22
- enableNativeCrashHandling?: boolean;
23
- /** Maximum time to wait to drain the request queue, before the process is allowed to exit. */
24
- shutdownTimeout?: number;
25
- sessionTrackingIntervalMillis?: number;
26
- /** Enable scope sync from Java to NDK on Android */
27
- enableNdkScopeSync?: boolean;
28
- /** When enabled, all the threads are automatically attached to all logged events on Android */
29
- attachThreads?: boolean;
30
- /**
31
- * When enabled, certain personally identifiable information (PII) is added by active integrations.
32
- *
33
- * @default false
34
- * */
35
- sendDefaultPii?: boolean;
36
- /** Should the native nagger alert be shown or not. */
37
- /**
38
- * Optional prefix to add while rewriting frames
39
- */
40
- appPrefix?: string;
41
- traceErrorHandler?: boolean;
42
- uncaughtErrors?: boolean;
43
- breadcrumbs?: {
44
- console?: boolean;
45
- dom?: boolean;
46
- fetch?: boolean;
47
- history?: boolean;
48
- sentry?: boolean;
49
- xhr?: boolean;
50
- };
51
- /** Enable auto performance tracking by default. */
52
- enableAutoPerformanceTracking?: boolean;
53
- flushSendEvent?: boolean;
54
- /**
55
- * Enables Out of Memory Tracking for iOS and macCatalyst.
56
- * See the following link for more information and possible restrictions:
57
- * https://docs.sentry.io/platforms/apple/guides/ios/configuration/out-of-memory/
58
- *
59
- * @default true
60
- * */
61
- enableOutOfMemoryTracking?: boolean;
62
- /**
63
- * Set data to the inital scope
64
- * @deprecated Use `Sentry.configureScope(...)`
65
- */
66
- initialScope?: CaptureContext;
67
- headers?: {
68
- [k: string]: string;
69
- };
70
- beforeSend?(event: any, hint?: any): any;
71
- }
72
- /** The Sentry Nativescript SDK Backend. */
73
- export declare class NativescriptBackend extends BaseBackend<BrowserOptions> {
74
- protected readonly _options: NativescriptOptions;
75
- private readonly _browserBackend;
76
- /** Creates a new Nativescript backend instance. */
77
- constructor(_options: NativescriptOptions);
78
- /**
79
- * @inheritDoc
80
- */
81
- protected _setupTransport(): Transport;
82
- /**
83
- * If true, native client is availabe and active
84
- */
85
- private _isNativeTransportAvailable;
86
- /**
87
- * If native client is available it will trigger a native crash.
88
- * Use this only for testing purposes.
89
- */
90
- nativeCrash(): void;
91
- /**
92
- * @inheritDoc
93
- */
94
- eventFromException(exception: any, hint?: EventHint): SyncPromise<Event>;
95
- /**
96
- * @inheritDoc
97
- */
98
- eventFromMessage(message: string, level?: Severity, hint?: EventHint): SyncPromise<Event>;
99
- }
100
- /**
101
- * Convert js severity level which has critical and log to more widely supported levels.
102
- * @param level
103
- * @returns More widely supported Severity level strings
104
- */
105
- export declare function _processLevel(level: Severity): Severity;
package/backend.js DELETED
@@ -1,78 +0,0 @@
1
- import { Transports } from '@sentry/browser';
2
- import { BrowserBackend } from '@sentry/browser/dist/backend';
3
- import { BaseBackend, NoopTransport } from '@sentry/core';
4
- import { Severity } from '@sentry/types';
5
- import { NativeTransport } from './transports/native';
6
- import { NSSentry } from './nssentry';
7
- /** The Sentry Nativescript SDK Backend. */
8
- export class NativescriptBackend extends BaseBackend {
9
- /** Creates a new Nativescript backend instance. */
10
- constructor(_options) {
11
- super(_options);
12
- this._options = _options;
13
- this._browserBackend = new BrowserBackend(_options);
14
- if (_options.enableNative !== false) {
15
- NSSentry.startWithDsnString(_options.dsn, _options);
16
- }
17
- }
18
- /**
19
- * @inheritDoc
20
- */
21
- _setupTransport() {
22
- if (!this._options.dsn) {
23
- // We return the noop transport here in case there is no Dsn.
24
- return new NoopTransport();
25
- }
26
- const transportOptions = Object.assign(Object.assign({}, this._options.transportOptions), { dsn: this._options.dsn });
27
- if (this._options.transport) {
28
- return new this._options.transport(transportOptions);
29
- }
30
- if (this._isNativeTransportAvailable()) {
31
- return new NativeTransport();
32
- }
33
- return new Transports.FetchTransport(transportOptions);
34
- }
35
- /**
36
- * If true, native client is availabe and active
37
- */
38
- _isNativeTransportAvailable() {
39
- return NSSentry.nativeClientAvailable && NSSentry.nativeTransport;
40
- }
41
- /**
42
- * If native client is available it will trigger a native crash.
43
- * Use this only for testing purposes.
44
- */
45
- nativeCrash() {
46
- if (this._options.enableNative) {
47
- // tslint:disable-next-line: no-unsafe-any
48
- NSSentry.crash();
49
- }
50
- }
51
- /**
52
- * @inheritDoc
53
- */
54
- eventFromException(exception, hint) {
55
- return this._browserBackend.eventFromException(exception, hint);
56
- }
57
- /**
58
- * @inheritDoc
59
- */
60
- eventFromMessage(message, level = Severity.Info, hint) {
61
- return this._browserBackend.eventFromMessage(message, level, hint);
62
- }
63
- }
64
- /**
65
- * Convert js severity level which has critical and log to more widely supported levels.
66
- * @param level
67
- * @returns More widely supported Severity level strings
68
- */
69
- export function _processLevel(level) {
70
- if (level === Severity.Critical) {
71
- return Severity.Fatal;
72
- }
73
- if (level === Severity.Log) {
74
- return Severity.Debug;
75
- }
76
- return level;
77
- }
78
- //# sourceMappingURL=backend.js.map
package/backend.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"backend.js","sourceRoot":"","sources":["../src/backend.ts"],"names":[],"mappings":"AAAA,OAAO,EAAkB,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7D,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC1D,OAAO,EAAoC,QAAQ,EAAa,MAAM,eAAe,CAAC;AAGtF,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AACtD,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAwFtC,2CAA2C;AAC3C,MAAM,OAAO,mBAAoB,SAAQ,WAA2B;IAGhE,mDAAmD;IACnD,YAAsC,QAA6B;QAC/D,KAAK,CAAC,QAAQ,CAAC,CAAC;QADkB,aAAQ,GAAR,QAAQ,CAAqB;QAE/D,IAAI,CAAC,eAAe,GAAG,IAAI,cAAc,CAAC,QAAQ,CAAC,CAAC;QAEpD,IAAI,QAAQ,CAAC,YAAY,KAAK,KAAK,EAAE;YACjC,QAAQ,CAAC,kBAAkB,CAAC,QAAQ,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;SACvD;IACL,CAAC;IAED;;OAEG;IACO,eAAe;QACrB,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,EAAE;YACpB,6DAA6D;YAC7D,OAAO,IAAI,aAAa,EAAE,CAAC;SAC9B;QAED,MAAM,gBAAgB,mCACf,IAAI,CAAC,QAAQ,CAAC,gBAAgB,KACjC,GAAG,EAAE,IAAI,CAAC,QAAQ,CAAC,GAAG,GACzB,CAAC;QAEF,I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are added
3
- */
4
- export declare function _addTracingExtensions(): void;
package/measurement.js DELETED
@@ -1,50 +0,0 @@
1
- import { getCurrentHub, getMainCarrier } from '@sentry/hub';
2
- import { NativescriptTracing } from './tracing';
3
- /**
4
- * Adds React Native's extensions. Needs to be called after @sentry/tracing's extension methods are added
5
- */
6
- export function _addTracingExtensions() {
7
- const carrier = getMainCarrier();
8
- if (carrier.__SENTRY__) {
9
- carrier.__SENTRY__.extensions = carrier.__SENTRY__.extensions || {};
10
- if (carrier.__SENTRY__.extensions.startTransaction) {
11
- const originalStartTransaction = carrier.__SENTRY__.extensions
12
- .startTransaction;
13
- /*
14
- Overwrites the transaction start and finish to start and finish stall tracking.
15
- Preferably instead of overwriting add a callback method for this in the Transaction itself.
16
- */
17
- const _startTransaction = _patchStartTransaction(originalStartTransaction);
18
- carrier.__SENTRY__.extensions.startTransaction = _startTransaction;
19
- }
20
- }
21
- }
22
- /**
23
- * Overwrite the startTransaction extension method to start and end stall tracking.
24
- */
25
- const _patchStartTransaction = (originalStartTransaction) => {
26
- /**
27
- * Method to overwrite with
28
- */
29
- function _startTransaction(transactionContext, customSamplingContext) {
30
- const transaction = originalStartTransaction.apply(this, [
31
- transactionContext,
32
- customSamplingContext,
33
- ]);
34
- const reactNativeTracing = getCurrentHub().getIntegration(NativescriptTracing);
35
- if (reactNativeTracing) {
36
- reactNativeTracing.onTransactionStart(transaction);
37
- // eslint-disable-next-line @typescript-eslint/unbound-method
38
- const originalFinish = transaction.finish;
39
- transaction.finish = (endTimestamp) => {
40
- if (reactNativeTracing) {
41
- reactNativeTracing.onTransactionFinish(transaction);
42
- }
43
- return originalFinish.apply(transaction, [endTimestamp]);
44
- };
45
- }
46
- return transaction;
47
- }
48
- return _startTransaction;
49
- };
50
- //# sourceMappingURL=measurement.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"measurement.js","sourceRoot":"","sources":["../src/measurement.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,aAAa,EAAE,cAAc,EAAE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CAAC,WAAW,EAAE,CAAC,YAAY,CAAC,CAAC,CAAC;YAC7D,CAAC,CAAC;SACL;QAED,OAAO,WAAW,CAAC;IACvB,CAAC;IAED,OAAO,iBAAiB,CAAC;AAC7B,CAAC,CAAC"}
@@ -1,30 +0,0 @@
1
- import { Breadcrumb, Event, Response, User } from '@sentry/types';
2
- import { NativescriptOptions } from './backend';
3
- import { UserFeedback } from './nssentry';
4
- export declare namespace NSSentry {
5
- const nativeClientAvailable = true;
6
- const nativeTransport = true;
7
- function sendEvent(event: Event): Promise<Response>;
8
- function captureEnvelope(envelope: string): Promise<void>;
9
- function flush(timeout: number): void;
10
- function startWithDsnString(dsnString: string, options?: NativescriptOptions): Promise<Response>;
11
- function disableNativeFramesTracking(): void;
12
- function fetchNativeSdkInfo(): {};
13
- function fetchNativeRelease(): {
14
- id: any;
15
- version: any;
16
- build: string;
17
- };
18
- function closeNativeSdk(): void;
19
- function crash(): void;
20
- function deviceContexts(): Promise<any>;
21
- function captureUserFeedback(feedback: UserFeedback): void;
22
- function setUser(user: User | null, otherUserKeys: any): void;
23
- function setTag(key: string, value: string): void;
24
- function setExtra(key: string, extra: string): void;
25
- function addBreadcrumb(breadcrumb: Breadcrumb, maxBreadcrumbs?: number): void;
26
- function clearBreadcrumbs(): void;
27
- function setContext(key: string, context: {
28
- [key: string]: any;
29
- } | null): void;
30
- }