rrweb icon indicating copy to clipboard operation
rrweb copied to clipboard

repro: adding node to <style> clears injected styles

Open billyvg opened this issue 1 year ago • 2 comments

Here is a repro of a case where a mutation that adds a node to a <style> (at least I think this is what parentId=-2 is) will clear the previously injected styles. This ends up clearing the noscript css so that the contents of the noscript elements will be displayed in the replay.

billyvg avatar Apr 24 '24 19:04 billyvg

⚠️ No Changeset found

Latest commit: d47ad209f7ed116d13ad3a8b867101d00864b2e6

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

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

changeset-bot[bot] avatar Apr 24 '24 19:04 changeset-bot[bot]

parentId === -2 means the parent node is ignored in terms of slimDom settings.

There is parentId: -1 in this test case which shouldn't happen I believe (if that is possible we should add a record-time test too)

I haven't tried to recreate yet..

eoghanmurray avatar Apr 30 '24 15:04 eoghanmurray