diff --git a/src/replay/index.ts b/src/replay/index.ts index 1c345fda..22df9d1e 100644 --- a/src/replay/index.ts +++ b/src/replay/index.ts @@ -409,7 +409,7 @@ export class Replayer { for (const attributeName in mutation.attributes) { if (typeof attributeName === 'string') { const value = mutation.attributes[attributeName]; - if (value) { + if (value !== null) { ((target as Node) as Element).setAttribute( attributeName, value, diff --git a/typings/record/collection.d.ts b/typings/record/collection.d.ts new file mode 100644 index 00000000..c6eb7fed --- /dev/null +++ b/typings/record/collection.d.ts @@ -0,0 +1,4 @@ +import { removedNodeMutation } from '../types'; +export declare function deepDelete(addsSet: Set, n: Node): void; +export declare function isParentRemoved(removes: removedNodeMutation[], n: Node): boolean; +export declare function isParentDropped(droppedSet: Set, n: Node): boolean;