fix: add prefer-dom-node-append rule (#5108)

This commit is contained in:
LongYinan
2023-11-29 04:43:39 +00:00
parent 123f091e5b
commit 23cfc58fe2
10 changed files with 12 additions and 11 deletions
@@ -12,7 +12,7 @@ export const RootBlockHub = () => {
if (div.hasChildNodes()) {
div.removeChild(div.firstChild as ChildNode);
}
div.appendChild(blockHub);
div.append(blockHub);
}
}
}, [blockHub]);
@@ -134,7 +134,7 @@ const BlockSuiteEditorImpl = ({
if (!container) {
return;
}
container.appendChild(editor);
container.append(editor);
return () => {
container.removeChild(editor);
};