@sentry/replay 0.5.16 → 0.5.18

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.
@@ -66,7 +66,7 @@ export declare class SentryReplay implements Integration {
66
66
  private initialState;
67
67
  private context;
68
68
  session: Session | undefined;
69
- constructor({ flushMinDelay, flushMaxDelay, initialFlushDelay, stickySession, useCompression, captureOnlyOnError, replaysSamplingRate, recordingConfig: { maskAllInputs, blockClass, ignoreClass, maskTextClass, ...recordingOptions }, }?: SentryReplayConfiguration);
69
+ constructor({ flushMinDelay, flushMaxDelay, initialFlushDelay, stickySession, useCompression, captureOnlyOnError, replaysSamplingRate, maskAllText, recordingConfig: { maskAllInputs, blockClass, ignoreClass, maskTextClass, ...recordingOptions }, }?: SentryReplayConfiguration);
70
70
  /**
71
71
  * Because we create a transaction in `setupOnce`, we can potentially create a
72
72
  * transaction before some native SDK integrations have run and applied their
@@ -221,15 +221,25 @@ export declare class SentryReplay implements Integration {
221
221
  popEventContext({ timestamp, }: {
222
222
  timestamp: number;
223
223
  }): Omit<CaptureReplayEventParams, 'includeReplayStartTimestamp' | 'segmentId' | 'replayId'>;
224
- runFlush(): Promise<void>;
225
224
  /**
226
225
  * Flushes replay event buffer to Sentry.
227
226
  *
228
- * Performance events are only added right before flushing - this is probably
227
+ * Performance events are only added right before flushing - this is
229
228
  * due to the buffered performance observer events.
230
229
  */
231
- flushUpdate: () => Promise<void>;
232
- throttledFlushUpdate: import("lodash").DebouncedFunc<() => Promise<void>>;
230
+ runFlush(): Promise<void>;
231
+ /**
232
+ * Flush recording data to Sentry. Creates a lock so that only a single flush
233
+ * can be active at a time.
234
+ */
235
+ flush: () => Promise<void>;
236
+ /**
237
+ * A throttled `flush()` that is called after a flush is completed and there
238
+ * are other queued flushes.
239
+ *
240
+ * Instead of calling a flush for every <n> queued flush, condense it to a single call
241
+ */
242
+ throttledFlush: import("lodash").DebouncedFunc<() => Promise<void>>;
233
243
  /**
234
244
  * Send replay attachment using `fetch()`
235
245
  */
@@ -238,6 +248,6 @@ export declare class SentryReplay implements Integration {
238
248
  /**
239
249
  * Finalize and send the current replay event to Sentry
240
250
  */
241
- sendReplay(replayId: string, events: RecordedEvents, segmentId: number): Promise<true | undefined>;
251
+ sendReplay(replayId: string, events: RecordedEvents, segmentId: number): Promise<unknown>;
242
252
  }
243
253
  export {};
@@ -61,6 +61,10 @@ export interface SentryReplayPluginOptions {
61
61
  * The sampling rate for replays. 1.0 will record all replays, 0 will record none.
62
62
  */
63
63
  replaysSamplingRate?: number;
64
+ /**
65
+ * Mask all text in recordings. All text will be replaced with asterisks by default.
66
+ */
67
+ maskAllText?: boolean;
64
68
  }
65
69
  export interface SentryReplayConfiguration extends SentryReplayPluginOptions {
66
70
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sentry/replay",
3
- "version": "0.5.16",
3
+ "version": "0.5.18",
4
4
  "description": "User replays for Sentry",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.es.js",