diff --git a/packages/rrweb/src/record/observer.ts b/packages/rrweb/src/record/observer.ts index 9048f7e676..68ab239e1f 100644 --- a/packages/rrweb/src/record/observer.ts +++ b/packages/rrweb/src/record/observer.ts @@ -52,7 +52,7 @@ import type { } from '@rrweb/types'; import MutationBuffer from './mutation'; import { callbackWrapper } from './error-handler'; -import dom, { mutationObserverCtor } from '@rrweb/utils'; +import dom, { mutationObserver as mutationObserverCtor } from '@rrweb/utils'; export const mutationBuffers: MutationBuffer[] = []; diff --git a/packages/utils/src/index.ts b/packages/utils/src/index.ts index 9fac4757c4..b88d7f452e 100644 --- a/packages/utils/src/index.ts +++ b/packages/utils/src/index.ts @@ -204,3 +204,18 @@ export function querySelectorAll( export function mutationObserverCtor(): (typeof MutationObserver)['prototype']['constructor'] { return getUntaintedPrototype('MutationObserver').constructor; } + +export default { + childNodes, + parentNode, + parentElement, + textContent, + contains, + getRootNode, + host, + styleSheets, + shadowRoot, + querySelector, + querySelectorAll, + mutationObserver: mutationObserverCtor, +};