Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .size-limit.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ module.exports = [
path: 'packages/browser/build/npm/esm/index.js',
import: createImport('init', 'browserTracingIntegration', 'replayIntegration'),
gzip: true,
limit: '68 KB',
limit: '70 KB',
modifyWebpackConfig: function (config) {
const webpack = require('webpack');
const TerserPlugin = require('terser-webpack-plugin');
Expand Down
2 changes: 2 additions & 0 deletions packages/replay-internal/src/integration.ts
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,8 @@ export class Replay implements Integration {
// this can happen if the error is frozen or does not allow mutation for other reasons
}
},
// experimental support for recording iframes from different origins
recordCrossOriginIframes: Boolean(_experiments.recordCrossOriginIframes),
};

this._initialOptions = {
Expand Down
5 changes: 5 additions & 0 deletions packages/replay-internal/src/types/replay.ts
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,11 @@ export interface ReplayPluginOptions extends ReplayNetworkOptions {
captureExceptions: boolean;
traceInternals: boolean;
continuousCheckout: number;
/**
* Before enabling, please read the security considerations:
* https://github.com/rrweb-io/rrweb/blob/master/docs/recipes/cross-origin-iframes.md#considerations
*/
recordCrossOriginIframes: boolean;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could leave a note here for security concerns and link to https://github.com/rrweb-io/rrweb/blob/master/docs/recipes/cross-origin-iframes.md

autoFlushOnFeedback: boolean;
}>;
}
Expand Down
1 change: 1 addition & 0 deletions packages/replay-internal/src/types/rrweb.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ export type RrwebRecordOptions = {
maskTextSelector?: string;
blockSelector?: string;
maskInputOptions?: Record<string, boolean>;
recordCrossOriginIframes?: boolean;
} & Record<string, unknown>;

export interface CanvasManagerInterface {
Expand Down
3 changes: 3 additions & 0 deletions packages/replay-internal/test/integration/rrweb.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ describe('Integration | rrweb', () => {
"maskTextFn": undefined,
"maskTextSelector": ".sentry-mask,[data-sentry-mask]",
"onMutation": [Function],
"recordCrossOriginIframes": false,
"slimDOMOptions": "all",
"unblockSelector": "",
"unmaskTextSelector": "",
Expand Down Expand Up @@ -80,6 +81,7 @@ describe('Integration | rrweb', () => {
"maskTextFn": undefined,
"maskTextSelector": ".sentry-mask,[data-sentry-mask]",
"onMutation": [Function],
"recordCrossOriginIframes": false,
"slimDOMOptions": "all",
"unblockSelector": "",
"unmaskTextSelector": "",
Expand Down Expand Up @@ -131,6 +133,7 @@ describe('Integration | rrweb', () => {
"maskTextFn": undefined,
"maskTextSelector": ".sentry-mask,[data-sentry-mask]",
"onMutation": [Function],
"recordCrossOriginIframes": false,
"sampling": {
"mousemove": false,
},
Expand Down
Loading