Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow more fine grained control over blocking elements #1642

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

kevinatown
Copy link
Contributor

This PR introduces a new option blockElementFN to rrweb.record options. This option allows the consumer to add a callback function to have more control over if the element is blocked or not. This will allow consumers to have a very strict blocking policy and whitelist content.

Copy link

changeset-bot bot commented Feb 3, 2025

🦋 Changeset detected

Latest commit: b0a72d2

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 19 packages
Name Type
rrweb-snapshot Patch
rrweb Patch
@rrweb/types Patch
rrdom Patch
rrdom-nodejs Patch
rrweb-player Patch
@rrweb/all Patch
@rrweb/replay Patch
@rrweb/record Patch
@rrweb/packer Patch
@rrweb/utils Patch
@rrweb/web-extension Patch
rrvideo Patch
@rrweb/rrweb-plugin-console-record Patch
@rrweb/rrweb-plugin-console-replay Patch
@rrweb/rrweb-plugin-sequential-id-record Patch
@rrweb/rrweb-plugin-sequential-id-replay Patch
@rrweb/rrweb-plugin-canvas-webrtc-record Patch
@rrweb/rrweb-plugin-canvas-webrtc-replay Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@eoghanmurray
Copy link
Contributor

There was an effort in #1541 to merge the two previous block methods into one argument that could be passed down. That's not a requirement to get this merged, but just to make note.

@kevinatown
Copy link
Contributor Author

Oh interesting. It seems that they were thinking about something similar: #1541 (comment). Happy to tackle that and remove the other two options, but that would be a breaking change and bigger than just a patch. Also willing to do it as a follow up.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants