diff --git a/packages/rrweb-snapshot/src/utils.ts b/packages/rrweb-snapshot/src/utils.ts index e2240d1ed9..4b04fbed04 100644 --- a/packages/rrweb-snapshot/src/utils.ts +++ b/packages/rrweb-snapshot/src/utils.ts @@ -108,8 +108,13 @@ export function stringifyStylesheet(s: CSSStyleSheet): string | null { if (!rules) { return null; } + let sheetHref = s.href; + if (!sheetHref && s.ownerNode && s.ownerNode.ownerDocument) { + // an inline