Skip to content

Commit

Permalink
fix replay crash in live mode
Browse files Browse the repository at this point in the history
  • Loading branch information
Vadman97 committed Oct 1, 2024
1 parent 63d3342 commit 35e3b96
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion packages/rrweb-snapshot/src/rebuild.ts
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,11 @@ function buildNode(
} else if (tagName === 'textarea' && name === 'value') {
// create without an ID or presence in mirror
node.appendChild(doc.createTextNode(value));
n.childNodes = []; // value overrides childNodes
try {
n.childNodes = []; // value overrides childNodes
} catch (err: unknown) {
console.warn(`Highlight failed to set rrweb text area child nodes ${err}`);
}
continue;
}

Expand Down

0 comments on commit 35e3b96

Please sign in to comment.